Click here to Skip to main content
15,901,284 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
how to stop events on page load on the enter click in asp.net .please help me as soon as possible
Posted
Comments
Kashinath Patil 1-Sep-12 3:50am    
Question is not getting Please give more details...
[no name] 1-Sep-12 3:55am    
i have the form employee master in which i have button new and my form contains text boxes.when i enter some values on my text boxes and after that i press enter it will cause an event fire n i.e.new button.how it can be stopped

Try:
C#
if (!Page.IsPostBack)
   {
   // Do load events
   ...
   }
 
Share this answer
 
Hi,

Make sure you have not defined DefaultButton property in your page. If you have specified then it will call your button event when you hit Enter key.

Please check DefaultButton Property[^]

Thanks
-Amit Gajjar
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900