int = InsertItem(hParent, hInsertAfter
, item
)
Inserts an item into the list.
Parameters
hParent : HTREEITEM
The parent item. If commctrl.TVI_ROOT or 0, it
is added to the root.hInsertAfter : HTREEITEM
The item to insert after. Can be an
item or TVI_FIRST, TVI_LAST or TVI_SORTitem : TV_ITEM
A tuple describing the new item.Alternative Parameters
mask
Integer specifying which attributes to set
text
The text of the item.
image
The index of the image to use.
selectedImage
The index of the items selected image.
state
The initial state of the item.
stateMask
Specifies which bits of the state are valid.
lParam
A user defined object for the item.
parent
The parent of the item.
parent
The parent of the item.
Alternative Parameters
text
The text for the item.
image
The index of the image to use.
selectedImage
The index of the items selected image.
parent
The parent of the item.
insertAfter
The item to
insert the new item after, or TVI_FIRST, TVI_LAST or TVI_SORT
Alternative Parameters
text
The text for the item.
parent
The parent of the item.
parent
The parent of the item.