hide and show the textbox in the webform....
-
i have a webform , in that webform there r 2 controls, 1. dropdownlist 2. textbox. initially the textbox is in hidden status. whenever the user selected the "NEW" option in the dropdownlist.. i like to show up the textbox and allow the user to enter the data.if the user again select some other option .. i like to hide the text box... do the show & hide the text box without refreshing the page.
-
i have a webform , in that webform there r 2 controls, 1. dropdownlist 2. textbox. initially the textbox is in hidden status. whenever the user selected the "NEW" option in the dropdownlist.. i like to show up the textbox and allow the user to enter the data.if the user again select some other option .. i like to hide the text box... do the show & hide the text box without refreshing the page.
use javascript in the dropdownlist add something like onchange="showHide()" then with javascript - function showHide() { if(document.getElementById("txtboxID").style.display == "none") document.getElementById("txtboxID").style.display = "block"; else document.getElementById("txtboxID").style.display = "none"; }