treeNinja
03-16-2009, 09:04 PM
Hi Please help, i am terribly confused and never encountered this before.
I have a search screen which based on the dropdown box choice, displays fields, name address etc.
So i select the dropdown box and choose "First Name / Last Name". I input values into the newly displayed FName and LName text boxes that are displayed.
Search executes and returns values, the Combo Box displays "First Name / Last Name". However I want it to return to the default Combo Box value.
(This is coming from the lead not me i know its foolish).
So i use
var selection = document.getElementById("ComboBox0");
selection.selectedIndex = 0;
and if I run AFTER the above line
alert(selection.selectedIndex);
alert(selection.value);
I see 0 and Default
BUT the text within the combo box is still displayed as "First Name / Last Name"
what am i doing wrong here?
I have a search screen which based on the dropdown box choice, displays fields, name address etc.
So i select the dropdown box and choose "First Name / Last Name". I input values into the newly displayed FName and LName text boxes that are displayed.
Search executes and returns values, the Combo Box displays "First Name / Last Name". However I want it to return to the default Combo Box value.
(This is coming from the lead not me i know its foolish).
So i use
var selection = document.getElementById("ComboBox0");
selection.selectedIndex = 0;
and if I run AFTER the above line
alert(selection.selectedIndex);
alert(selection.value);
I see 0 and Default
BUT the text within the combo box is still displayed as "First Name / Last Name"
what am i doing wrong here?