In the onclientclick event of a button, I have a javascript code that returns either true or false. My question is that Onclick event of that button should fire only if onclientclick returns true otherwise not.
Button Onclick and OnClientClick Event should not fire together
Collapse
X
-
Tags: None
-
If you have Javascript validation is client side. The onclick event is server side. The client always runs first. Hope this helps. -
Please check out this article about How to use JavaScript in ASP.NET. If you still have questions after you read it, post back here :)Comment
Comment