This method adds a Node object to the Nodes collection of a TreeView control.
nodes.Add([relative], [relationship], [key], text, [image], [selectedimage])
Reference to the new Node object.
The following table shows the possible values for the relationship parameter.
Constant |
Value |
Description |
tvwFirst | 0 | First. Node is placed before all other nodes at the same level of the node named in relative. |
TvwLast | 1 | Last. Node is placed after all other nodes at the same level of the node named in relative. Any Node added subsequently may be placed after the one added as Last. |
TvwNext | 2 (Default) | Next. Node is placed after the node named in relative. |
TvwPrevious | 3 | Previous. Node is placed before the node named in relative. |
TvwChild | 4 | Child. Node becomes a child node of the node named in relative. |
If no Node object is named in relative, the new node is placed in the last position of the top node hierarchy.