RemoveItem

Parent Previous Next

RemoveItem

This function will remove the selected item in the combo-box object.


Function Definition:


void RemoveItem(int index);


.     int index: An integer parameter containing the index of the item that will be removed.



To configure this function, follow the steps below:


1.   In an object event, configure the RemoveItem() function: ComboBoxObjectName.RemoveItem(index);


2.   Run the configured event to remove the selected item.



Example:


In the graphic document, the user has one Combo-Box object (named as ComboBox1) with 3 items configured: "Item1", "Item2" and "Item3". In a Button object (named as Button1) the user configures the MouseUp event with the following event:


ComboBox1.RemoveItem(1);


In this event, the Combo-Box will remove the item "Item2" from the list so the combo-box object now will only exhibit the items: "Item1" and "Item3".


  

 

Note: The list of items in the combo-box object starts with index 0 (zero).

  

 

Note: This property exists only to the following objects:

.     Combo-Box