TreeView.setSelectedImageIndex

Overview | Methods | This Package | All Packages

TreeView.setSelectedImageIndex

Sets the index of the image that appears next to the node that is currently selected in the tree view control.

Syntax

public void setSelectedImageIndex( int value )

Parameters

value

The zero-based index within an ImageList object of the image that you want to appear next to a node when it is selected in the tree view control. The default value is zero (0).

Remarks

To display images in a tree view control, you must create an ImageList object, add images to the ImageList object, associate the ImageList object with the TreeView control using the setImageList method, and specify which image to display next to nodes in the tree view using the setImageIndex method. If you want a different image to display next to a node when it is selected, use the setSelectedImageIndex method.

See Also   getSelectedImageIndex