WinStudio
IWSFormComponent interface, list source objects
Returns the index number of the currently selected item in a list source.
object.ListIndex
Part |
Description |
object | Required. A reference to a form component object. |
The return value is an integer indicating the index number of the currently selected item in the list source for a list box, drop list, or combo box. The list source cannot be a grid column.
Sub Main() Dim iListIndex As Integer iListIndex = ThisForm.Components("comboBox1").ListIndex Application.ShowMessage(iListIndex.ToString()) End Sub