Tree-AddParent

Function Name dcl-Tree-AddParent
Syntax   (dcl-Tree-AddParent <CONTROL> (List of Lists as (Label [as String] {Key [as String]} {ImageIndex [as Integer]} {SelectedImageIndex [as Integer]} {ExpandedImageIndex [as Integer]}) ...))
Return Type Handle or Boolean (T if successful; otherwise NIL)
Applies To Tree

This method appends one or more new top level parent items to the tree. Label is the label text for the new item. If Key is specified, it must be a unique (to the tree control instance) string key to be used for identifying the new item. The three optional ImageIndex arguments are images from the control's image list that display when the item is in the normal, selected, or expanded states, respectively. The return value is the unique handle of the new item if only one item is added; if multiple items are added in one call, the return value is T if the call was successful or NIL otherwise.

This method supports an alternative syntax when adding only a single item. The alternative syntax does not require the arguments to be in nested lists.