select node in TreeNode
조회 수: 11 (최근 30일)
이전 댓글 표시
hi, a is a parents and b is a children (see pics)
i want to select children using code
How can i do it?
댓글 수: 0
채택된 답변
Divyajyoti Nayak
2024년 10월 14일
편집: Divyajyoti Nayak
2024년 10월 18일
I assume you want to programmatically "check" the child node checkbox. The "CheckedNodes" property of the parent "Tree" object can be used to achieve this. Here's the documentation link to help you out:
Here's some sample code to "check" the child node:
app.Tree.CheckedNodes = [app.Tree.CheckedNodes app.ChildNode];
%app.Tree is the parent Tree object
%app.ChildNode is the tree node that needs to be checked
If you want to "select" the child node and not "check" it, then similarly, the "SelectedNodes" property can be used.
Hope this helps!
댓글 수: 0
추가 답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Graphics Object Programming에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!