User Guide

ComboBox component 187
ComboBox.addItemAt()
Availability
Flash Player 6 (6.0 79.0).
Edition
Flash MX 2004.
Usage
comboBoxInstance.addItemAt(index, label[, data])
comboBoxInstance.addItemAt(index, {label:label[, data:data]})
comboBoxInstance.addItemAt(index, obj);
Parameters
index
A number 0 or greater that indicates the position at which to insert the item (the index
of the new item).
label A string that indicates the label for the new item.
data The data for the item; it can be of any data type. This parameter is optional.
obj An object with label and data properties.
Returns
The index at which the item was added.
Description
Method; adds a new item to the end of the list at the index specified by the index parameter.
Indices greater than
ComboBox.length are ignored.
Example
The following code inserts an item at index 3, which is the fourth position in the combo box list
(0 is the first position):
myBox.addItemAt(3, "this is the fourth Item");
ComboBox.change
Availability
Flash Player 6 (6.0 79.0).
Edition
Flash MX 2004.
Usage
Usage 1:
on(change){
// your code here
}