Click here to Skip to main content
15,892,537 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hi,

I have five textbox with required field validator. And one Button with Onclientclick i need to show some message.

Here i need to check the requiredfield validator before the client click msg box

I am using ASP.Net

Please help me to achive this

Thanks
Mohan
Posted

1 solution

in your on client click function call Page_ClientValidate
sample code
JavaScript
<script type="text/javascript" language="javascript">
function ClientClickFunction() {
if (Page_ClientValidate())
{
// do sumething
}else
{
// do something
}
}
</script>
 
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