TreeList.ExpandToLevel(Int32) Method

Expands nodes up to the specified level.

Namespace: DevExpress.XtraTreeList

Assembly: DevExpress.XtraTreeList.v20.1.dll


public virtual void ExpandToLevel(
    int level
Public Overridable Sub ExpandToLevel(
    level As Integer


Name Type Description
level Int32

A System.Int32 value that specifies the level up to which nodes should be expanded.


The TreeList displays data in a hierarchical structure using nodes (TreeListNode objects). The hierarchical level of a certain TreeListNode can be obtained with the TreeListNode.Level property. Nodes can be expanded to display nested nodes. To expand a particular node, set the TreeListNode.Expanded property to true.

The ExpandToLevel method expands nodes up to the specified level. For instance, calling the ExpandToLevel method with the level parameter set to 0, expands all root nodes.

See Also