L
Lisa Calla
Hi,
I have a composite control made of a textbox and a label. I want to show
either the textbox or the label, and hide the other control on the client
side in response to a click. I can run a function belonging to the control,
but I can't seem to alter the visibility of the children. My composite
control has this client-side code:
function disable() {
alert('In disable');
document.getElementById("TextBox1").style.display="none";
document.getElementById("Label1").style.display="inline";
alert('After disable');
return false;
}
I see both alerts, but the code does nothing. Any suggestions?
I have a composite control made of a textbox and a label. I want to show
either the textbox or the label, and hide the other control on the client
side in response to a click. I can run a function belonging to the control,
but I can't seem to alter the visibility of the children. My composite
control has this client-side code:
function disable() {
alert('In disable');
document.getElementById("TextBox1").style.display="none";
document.getElementById("Label1").style.display="inline";
alert('After disable');
return false;
}
I see both alerts, but the code does nothing. Any suggestions?