pyWinAuto: pywinauto.controls.win32_controls.ListBoxWrapper -- Wrap a windows ListBox control

ListBoxWrapper

Wrap a windows ListBox control


Attributes

a windowclasses

['ListBox', 'WindowsForms\\d*\\.LISTBOX\\..*', 'TListBox']

a handle

None

a friendlyclassname

'ListBox'

Methods

f __init__(self, hwnd) ...

Initialize the control

f SelectedIndices(self) ...

The currently selected indices of the listbox

f ItemCount(self) ...

Return the number of items in the ListBox

f ItemData(self, i) ...

Return the ItemData if any associted with the item

f ItemTexts(self) ...

Return the text of the items of the listbox

f Texts(self) ...

Return the texts of the control

f Select(self, item) ...

Select the ListBox item

item can be either a 0 based index of the item to select or it can be the string that you want to select

f SetItemFocus(self, item) ...

Set the ListBox focus to the item at index

f GetItemFocus(self) ...

Retrun the index of current selection in a ListBox

f __eq__(self, other) ...

Returns True if the handles of both controls are the same

See the source for more information.