Description

Inserts a new tree node in the tree node collection at the specified location.

Syntax

object.Insert( index, text, imageIndex, selectedImageIndex )

Parameters

index - The indexed location within the collection to insert the tree node.

text - the label text displayed by the TreeNode.

imageIndex - the index value of image to display when the tree node is unselected.

selectedImageIndex - the index value of Image to display when the tree node is selected.

Return Value

A TreeNode that represents the tree node being inserted into the collection.

Remarks

If the TreeView.Sorted property is set to true, the index parameter value is ignored. The TreeNode is inserted into the tree view and the TreeView resorted. You can also add new TreeNode objects to the collection by using the Add method. To remove a TreeNode that you previously added, use the Remove or Clear methods.

See Also

Applies To: TreeNodeCollection


The CHM file was converted to HTML by chm2web software.