Sign in Join
FPDoc Onlineexperiment

TTreeNodes.Clear procedure

Member of TTreeNodespublicIn unit ComCtrls

Removes tree nodes in the container and its internal cache.

Declaration

pascal
procedure Clear; virtual

Description

Clear is a method used to remove all of the existing TTreeNode instances found in the container. In addition, the internal TNodeCache for the container is cleared.

Clear visits the tree nodes in the container and calls its Delete method to physically remove the node. This process is repeated until there a TTreeNode instance is not available from the GetLastNode method. The internal selection list for the container is cleared, as are child accessibility objects in the Owner (TCustomTreeView).

Clear encloses these operations with BeginUpdate and EndUpdate to prevent updates to the container while the method is active.

See also

An experiment, built from development snapshots. Not the official Free Pascal or Lazarus documentation.