Remove the highlighting from all items in either a Single-selection or a Multiple-select List Box.
cClearLBAll (window-handle)
(i) window-handle Windows handle to a List Box control.
(i) @TRUE, If all items are unselected. @FALSE, If one or more items are still selected.
Use this function to remove the highlighting from all items in either a Single-selection or a Multiple-select List Box. It is a good idea to call this function before calling cSetLBItemEX on Multiple-select list boxes because the list box may have some items already selected.
If you pass in a handle to a list box that does not have any items selected cClearLBAll will not create an error and will return @TRUE.
The class name for List Box controls is "List Box".
AddExtender("wwctl44i.dll",0,"wwctl64i.dll")
;Get the handle of the parent window ;of the list box control. HwndParent=DllHwnd("Window Title") hwnd = cWndbyclass(hwndParent, "ListBox")
; Clear any current selections If !cClearLbAll(hwnd) Goto ErrorHandler EndIf
; Select the first and fifth items in the list If ! cSetLbItemEx(hwnd, "1 5") Goto ErrorHandler EndIf
; Get the selected items text SelectedText = cGetLbSelText(hwnd) SelectedText = StrReplace(SelectedText, @TAB, @CRLF) Message("Selected Text", SelectedText)