List property (WinStudio scripts)
Applies To
IWSFormComponent interface, list source objects
Definition
Returns the values in a list source for a list box, drop list, or combo box component.
Syntax
object.List
Part | Description |
object | Required. A reference to a form component object. |
Remarks
The return value is an ArrayList containing the values in the list source.
Example
Sub Main() Dim vFindResult As System.Collections.ArrayList Dim iNumItems As Integer Dim iCounter As Integer iNumItems = ThisForm.Components("comboBox1").NumListRows 'Get the list associated with comboBox1 and loop through it. For iCounter = 0 To iNumItems - 1 vFindResult = ThisForm.Components("comboBox1").List Application.ShowMessage(iCounter.ToString() & " " & vFindResult(iCounter).ToString()) Next iCounter End Sub