Shiny Language Reference

Language Reference > User Interface > List Boxes


resetlistbox

resetlistbox(int ID);

 

Synonyms:

resetlistboxcontent(int ID);

 

Removes all items in a list box

The RESETLISTBOX statement removes all items and any associated data in the specified listbox.

 

Parameters

ID

The control ID of the control to reset

 

Return Value

None

 

Example Code

// Create the edit box X: 10, Y:10 and sized 200*120
int iListBoxID = createlistbox(1, 10, 10, 200, 120);

// Add 25 test items
for(int iTest = 0; iTest < 25; iTest++)
    addlistboxitem(iListBoxID, "Test item " + iTest);


// Reset all data in the listbox
resetlistbox(iListBoxID);