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

# TTreeNodes.AddChildFirst

Adds a node with specified text as the first child of the parent node and returns the new node.

## Declaration

Source position: comctrls.pp line 3250

`public function TTreeNodes.AddChildFirst(`
`ParentNode: TTreeNode;`
`const S: string`
`):TTreeNode;`

## Arguments

`ParentNode` |  | Node which is the parent for the new child node.
`S` |  | Text for the child node created in the method.

## Function result

New child node created in the method.

## See also

TTreeNodes.InternalAddObject |  | Creates or updates a tree node with the specified text and a pointer to data.