on 12-21-2005 3:23 PM
Hi,
How can I call the "collapse all" action of the tree element the in code?
Thanks,
Aviad
Hello Aviad,
Let say you have node Entries and subnode SubEntries (recursive to Entries). Attribute IsExpanded is mapped to expanded property of treeNodeType. So you have to iterate and set appropriate status (true to expand or false to collapse) as Valery suggested in early mentioned post.
private void setNodeStatus(IPrivateXXX.IEntriesNode node, boolean status) {
for(int i=node.size();i>0;) {
final IPrivateXXX.IEntriesElement element = node.getEntriesElementAt(--i);
element.setIsExpanded(status);
if(element.getIsNode()) {
setNodeStatus(element.nodeSubEntries(), status);
}
}
}
Best regards, Maksim Rashchynski.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
89 | |
10 | |
10 | |
9 | |
6 | |
6 | |
6 | |
5 | |
4 | |
3 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.