|
it
newsgroups
|
|||||||||||||||||||||||
|
|||||||||||||||||||||||
Asp:Imagebutton and javascript
Hello,
I've an asp:Imagebutton on my form with the visible property set to false <asp:Imagebutton ID="tstImage" runat=Server visible=False> How can I set the visible propery to true using a javascript ? I tried something like document.GetElementById('ImgTest').visible='true'; but without succes .... Any idea ? Many thanks, KArel > How can I set the visible propery to true using a javascript ? You can't. If you're setting the visibility on the control, then that's> I tried something like document.GetElementById('ImgTest').visible='true'; > but without succes .... being controlled by the codebehind. If it's set to be visible="false" it won't even be rendered in the HTML. For what you want, I think you want to place the button in a DIV and then HIDE the div via javascript when the page loads. That way it's part of the DOM and you can then do what you want with it via javascript. -Darrel |
|||||||||||||||||||||||