tvInsertItem

Top  Previous  Next

Syntax

UINT = tvInsertItem(win as WINDOW,id as INT,strText as STRING,parent as UINT)

Description

Inserts a new item into the tree view control.

Parameters

win - Window or dialog containing the control.

id - Identifier of the tree view control.

strText - Text of the new item.

parent - Handle to the parent item or NULL to insert a new root item.

Return value

Returns TRUE (1) if successful, FALSE (0) on failure.

Remarks

See Also: tvDeleteItem

Example usage

root1 = tvInsertItem(win,11,"Item 1",0)
child1 = tvInsertItem(win,11,"child 1",root1)
tvInsertItem(win,11,"Child of child1",child1)