:: Forum >>
Reset Combo Box
Does anyone know how to reset the selected index on a Combo Box, as in:
obj.selectedIndex = -1
Doesn't seem to be in the docs.
Wallace R
Thursday, November 9, 2006
obj.setSelectedItems([]);
Alex (ActiveWidgets)
Thursday, November 9, 2006
Nope, that was the first thing I tried and it didn't work. Here is the code I've used to declare the Combo Box:
var cmbComboBox = new AW.UI.Combo;
/*
set up attributes for cmbComboBox
*/
btnClear.onControlClicked = function()
{
cmbComboBox.setSelectedItems([]); //does nothing
};
Wallace R
Friday, November 10, 2006
Ah - got it.
Forgot to include setControlText() after setSelectedItems([]).
Wallace R
Friday, November 10, 2006
hi wallace can u plz write the both statements together i.e. setSelectedItems([]) & setControlText()
Saturday, November 11, 2006
Hi wallace will u please tell me how u hav done the above code ... I mean the correct syntax
Pallavi
Thursday, November 23, 2006
obj.setSelectedItems([]);
obj.setControlText("Enter Control Text Here");
Also to hide the popup use:
obj.hidePopup();
Wallace R
Thursday, November 23, 2006
This topic is archived.
Back to support forum
Forum search