Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Hidden fields

Status
Not open for further replies.

sabavno

Programmer
Jul 25, 2002
381
CA
Hi,

Depending on the value chosen in the combo box,I will hide or show the text box at the bottom.

How can I do that?

Thanks.
 
javascript.

on the comboBox add a "onChange" event:

onChange="myfunction(this.value)"

myfunction(myvalue) {
//depending on the value of the combobox
if (myvalue == ...) {
document.all.item("textboxID").style.display = '';
} else {
document.all.item("textboxID").style.display = 'none';
}
}


on the textbox add a style:
input type="text" id="textboxID" style="display:none"


hope this helps
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top