ListBox.setSelectedIndex

Overview | Methods | Fields | This Package | All Packages

ListBox.setSelectedIndex

Selects an item in a single-selection list box.

Syntax

public final void setSelectedIndex( int index )

Parameters

index

The zero-based index of the item you want to select. Set to -1 if you want no item to be selected.

Remarks

To select an item in a multiple-selection list box, use the setSelected method.

Exceptions

WFCInvalidArgumentException thrown if the specified index is not valid. WFCException thrown if the selectionMode property of the list box is set to SelectionMode.NONE.

See Also   getSelectedIndex