Edit this page

Bring a Node into View

In cases where you have a tree view with many nodes and limited space on the form, you need to scroll the control in order to find a specific node. RadTreeView control handles this automatically for you. To scroll the control to a node use the BringIntoView method.

RadTreeNode lastRootNode = radTreeView1.Nodes[radTreeView1.Nodes.Count - 1];
radTreeView1.BringIntoView(lastRootNode.Nodes[lastRootNode.Nodes.Count - 1]);

Dim lastRootNode As RadTreeNode = RadTreeView1.Nodes(RadTreeView1.Nodes.Count - 1)
RadTreeView1.BringIntoView(lastRootNode.Nodes(lastRootNode.Nodes.Count - 1))

important

The BringIntoView method does not select the node!

note

The RadTreeViewElement class defines an AutoScrollOnClick property which is by default set to true. This property determines whether to scroll horizontally the control ensuring that the clicked node is visible.

See Also

Is this article helpful? Yes / No
Thank you for your feedback!

Give article feedback

Tell us how we can improve this article

close
Dummy