ffur2007slx2_5
More information on the CT_LISTBOX command family can be found here.
Results appear below as you type; use the arrow keys to move through them.
Command · Markdown · JSON · original wiki page
Adds an item with the given text to the CT_LISTBOX or CT_COMBO or CT_TOOLBOX.
Note
If using
RscToolBoxas template with ctrlCreate, clear it first with lbClear
lbAdd [idc, text]
Parameters:
Returns: Number - index (row) of newly added item
control lbAdd text
Parameters:
Returns: Number - index (row) of newly added item
_index = lbAdd [101, "First item"];
_index = _control lbAdd "First item";
More information on the CT_LISTBOX command family can be found here.
This command can be very very frustrating to use because it does not output any errors if unable to function.
Often, the 2nd provided syntax needs to be used like this:
_giveYourControlAname = findDisplay 7 displayCtrl 9;
_addThisToListBox = "Option";
_giveYourControlAname lbAdd _addThisToListBox;
Where "7" is the "idd" of the dialog you made in your ".hpp" file and where "9" is the "idc" of the RscListBox or RscComboBox.
The code above will add an option named "Option" to the ListBox or ComboBox.