Home All Groups Group Topic Archive Search About
Author
19 Jul 2005 2:41 PM
Mesalem
i'm creating a text box dynamically in the page load and on the client side i
use the following script to hide the control

document.getElementById('dynamicText').style.display='none';
document.getElementById('dynamicText').style.visibility='hidden';

after a post back the control is displayed again
i examined the WebControl.Style properties and found that it's not affected
by the client script, so how can i handle this??

thanks in advance,
Mesalem

Author
19 Jul 2005 3:13 PM
Brock Allen
You will need to send something to the server to tell it to do the same thing
that was done in your client javascript. Pehrpas a hidden field of your own?
Page.RegisterHiddenField will gen one for you. Have your script fill this
in and then on the postback inspect it to know how to set the stype on the
server.

-Brock
DevelopMentor
http://staff.develop.com/ballen



Show quoteHide quote
> i'm creating a text box dynamically in the page load and on the client
> side i use the following script to hide the control
>
> document.getElementById('dynamicText').style.display='none';
> document.getElementById('dynamicText').style.visibility='hidden';
>
> after a post back the control is displayed again
> i examined the WebControl.Style properties and found that it's not
> affected
> by the client script, so how can i handle this??
> thanks in advance,
> Mesalem