ListIndex property (WinStudio scripts)

Applies To

IWSFormComponent interface, list source objects

Definition

Returns the index number of the currently selected item in a list source.

Syntax

object.ListIndex

  Part   Description
object Required. A reference to a form component object.

Remarks

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.

Example

Sub Main()
   Dim iListIndex As Integer
   iListIndex = ThisForm.Components("comboBox1").ListIndex
   Application.ShowMessage(iListIndex.ToString())
End Sub