Programmatically Show/Hide nodes in a tree


Author
Message
Nevron Support
Nevron Support
Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)Supreme Being (4.5K reputation)
Group: Administrators
Posts: 3.1K, Visits: 4.2K

You can use the ToggleState() method of the show/hide subtree decorator to achieve this:

showHideSubTreeDecorator.ToggleState();

document.SmartRefreshAllViews();

Note, that if you want to check if the decorator is currently expanded or not you can use its GetState() method.



Best Regards,
Nevron Support Team


Rotha Aing
Rotha Aing
Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)Forum Newbie (2 reputation)
Group: Forum Members
Posts: 2, Visits: 1
Hi,

Is there a way to programmatically set nodes to either be expanded or collapsed? I would like to create some controls that will go through the diagram and expand certain nodes while leaving others collapsed.

Currently I am using the NShowHideSubtreeDecorator.

Thanks
GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...




Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search