Solved

hide html reset button

Posted on 2009-05-05
5
329 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
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 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

The Orion Papers

Are you interested in becoming an AWS Certified Solutions Architect?

Discover a new interactive way of training for the exam.

Question has a verified solution.

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

More often than not, we developers are confronted with a need: a need to make some kind of magic happen via code. Whether it is for a client, for the boss, or for our own personal projects, the need must be satisfied. Most of the time, the Framework…
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…
There are cases when e.g. an IT administrator wants to have full access and view into selected mailboxes on Exchange server, directly from his own email account in Outlook or Outlook Web Access. This proves useful when for example administrator want…
In this brief tutorial Pawel from AdRem Software explains how you can quickly find out which services are running on your network, or what are the IP addresses of servers responsible for each service. Software used is freeware NetCrunch Tools (https…

726 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