Re: getIndex listview problem
- Posted by DerekParnell (admin) Feb 17, 2015
- 1161 views
DonCole said...
In win32.lib is says:
[func] getIndex ( list )
Get the index of the selected item(s), or cursor position in an edit control. Returns: INTEGER: Index of selected item, or zero if no item is selected.
My code:
object index1, index2 index1 = getIndex(LV_TOP) index2 = getIndex(LV_BOT)
This not true. When I run it I get () and (8) respectively which are sequences.
How do I get integers?
Thank you,
Don Cole
The documentation is incomplete. When the control being interrogated is a ListView, it returns a sequence.
It does this because it is possible for a List to have multiple items selected. The sequence returned, is a list of all the selected items in the nominated ListView.