By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
443,715 Members | 1,773 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 443,715 IT Pros & Developers. It's quick & easy.

label visible/invisible?

P: n/a
Hi,
How can i make a label visible/invisible? I am able to do it for text box by
using document.form1.TextBox1.style.visibility="hidden"; But when i am
giving the same for the label, i am getting an error.

any idea??

Nov 18 '05 #1
Share this Question
Share on Google+
4 Replies


P: n/a
Gibs

Instead of

blah.style.visibility = "hidden"

use

blah.style.display = "none"

To show the label, use

blah.style.display = "block"
HTH
E

Nov 18 '05 #2

P: n/a
put the label inside a <div id=mydiv> tag
and call window.mydiv.style.visibility="hidden"

Rajagopal Pasupuleti
*** Sent via Developersdex http://www.developersdex.com ***
Don't just participate in USENET...get rewarded for it!
Nov 18 '05 #3

P: n/a
Thanks for the reply.
I tried this , but i am getting a null error.
any idea?
"Gibs" <do*********@yahoo.com> wrote in message
news:eR**************@tk2msftngp13.phx.gbl...
Hi,
How can i make a label visible/invisible? I am able to do it for text box by using document.form1.TextBox1.style.visibility="hidden"; But when i am
giving the same for the label, i am getting an error.

any idea??

Nov 18 '05 #4

P: n/a
I used this and got it work

this.document.getElementById('Label1').style.visib ility="visible";

and to make hidden

this.document.getElementById('Label1').style.visib ility="hidden";

Thanks for all the help

"Gibs" <do*********@yahoo.com> wrote in message
news:O3****************@TK2MSFTNGP12.phx.gbl...
Thanks for the reply.
I tried this , but i am getting a null error.
any idea?
"Gibs" <do*********@yahoo.com> wrote in message
news:eR**************@tk2msftngp13.phx.gbl...
Hi,
How can i make a label visible/invisible? I am able to do it for text
box by
using document.form1.TextBox1.style.visibility="hidden"; But when i am
giving the same for the label, i am getting an error.

any idea??


Nov 18 '05 #5

This discussion thread is closed

Replies have been disabled for this discussion.