Solved

hide html reset button

Posted on 2009-05-05
5
325 Views
Last Modified: 2013-12-17
I have an HTML reset button which I would like to hide using c#.

I have trided doing reset.visible= false;

but this does not work.

can anybody help.
0
Comment
Question by:Mr_Shaw
  • 3
  • 2
5 Comments
 
LVL 39

Expert Comment

by:abel
ID: 24306452
How do you declare the reset button? If the ID of the reset button is "reset" and if the runat="server" is present, you can so with the code snippet you say... Otherwise, please show the declaration of the reset button and we go from there
0
 
LVL 39

Expert Comment

by:abel
ID: 24306492
If this is in your aspx:

<input type="reset" runat="server" id="myresetbutton" value="reset me" />
then this can go in your code behind to hide the reset button:

myresetbutton.Visible = false;
0
 

Author Comment

by:Mr_Shaw
ID: 24306504
<input id="Button2" type="reset" value="Reset" />

I have tride Button2.visible = false

and it does not work.
0
 
LVL 39

Accepted Solution

by:
abel earned 500 total points
ID: 24306546
see above (first and second comment): what you need is the runat="server" part. Without that, it will indeed not work. The runat="server" says to ASP.NET to use any ordinary HTML element and make it programmable.
0
 

Author Closing Comment

by:Mr_Shaw
ID: 31578096
thanks
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

In my previous two articles we discussed Binary Serialization (http://www.experts-exchange.com/A_4362.html) and XML Serialization (http://www.experts-exchange.com/A_4425.html). In this article we will try to know more about SOAP (Simple Object Acces…
Real-time is more about the business, not the technology. In day-to-day life, to make real-time decisions like buying or investing, business needs the latest information(e.g. Gold Rate/Stock Rate). Unlike traditional days, you need not wait for a fe…
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…
As a trusted technology advisor to your customers you are likely getting the daily question of, ‘should I put this in the cloud?’ As customer demands for cloud services increases, companies will see a shift from traditional buying patterns to new…

920 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

17 Experts available now in Live!

Get 1:1 Help Now