[Overview][Constants][Types][Classes][Procedures and functions][Index] | Reference for unit 'ComCtrls' (#lcl)

# TTreeNode.ExpandParents

Expands all tree nodes which are an ancestor of the current node.

## Declaration

Source position: comctrls.pp line 3142

`public procedure TTreeNode.ExpandParents;`

## Description

ExpandParents visits each tree node which is used as the Parent for a node, and sets its Expanded property to True.

ExpandParents is called from methods like MakeVisible and EnsureNodeIsVisible in TCustomTreeView.

## See also

TTreeNode.Parent |  | Parent node for the current tree node.
TTreeNode.Expanded |  | True if the node has been expanded, False when collapsed.
TTreeNode.MakeVisible |  | Forces the tree node to become visible.
TCustomTreeView.EnsureNodeIsVisible |  | Ensures parent nodes are expanded, and the specified node is visible in the control.