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

# TTreeNodes.GetSelections

Gets the tree node at the specified position in the list of selected nodes.

## Declaration

Source position: comctrls.pp line 3276

`public function TTreeNodes.GetSelections(`
`const AIndex: Integer`
`):TTreeNode;`

## Arguments

`AIndex` |  | Ordinal position in the selection list for the node.

## Function result

Tree node at the specified position in the selection list.

## Description

Raises an ETreeNodeError exception if AIndex is not a valid ordinal position in the internal selection list. AIndex must be in the range 0..SelectionCount-1.

## See also

TTreeNodes.SelectOnlyThis |  | Clears any existing multi-selections and selects the specified node.
TTreeNodes.SelectionCount |  | Number of tree nodes included in the internal selection list.
TTreeNodes.SelectionsChanged |  | Adds or removes the specified tree node to / from the internal selections list when its Selected property is changed.