setValue

selects an item in the options list

void setValue(string|number value);
valuestring|numberID of an option to select

Example

// master is a control with a popup list of options
var suggest = master.getPopup();
master.setValue(2);

Details

The method doesn't set value for the master control (text, combo, multicombo, richselect, multiselect), it selects an option in the suggest list only.

To set the value of the master control, apply the the setValue method to it.

See also
Back to top