The ListBox class is derived from the WinControl class
access function : GetListBox(name)
Attributes of the ListBox class
Attribute |
Access |
Type |
Description |
items |
R/W |
tuple |
the listbox items as a tuple of strings |
itemIndex |
R/W |
int |
index of current selection, zero indexed.
-1 if no selection |
selItem |
R/W |
string |
the currently selected item |
onClick |
W |
callback |
called when user clicks the control |
Example 1: Populate Listbox
listBox=GetListBox('somename')
listbox.items+=('57_003','57_004','57_005') #adds three new item to the listbox
listbox.selText='57_003' #selects one
|