views:

46

answers:

2

Hi

Asp.net validation controls generates client-side javascript that validates controls.

I decided to have a look into the ASP.NET validation JavaScript and I can see there is a function that hooks into the onchange events for controls to make sure the validation script runs when a values is changed.

My question:

Is there a way to disable this onchange validation? I want the validation to be done on the submit and then show the necessary error messages.

Thanks

A: 

Simply set:

EnableClientScript="False"

On the control.

Noon Silk
I think Morph still wants client side validation
RichardOD
Oh, right. Well, @OP, what control is automatically posting back on change? Just stop it.
Noon Silk
+1  A: 

Have a look at this article.

RichardOD
Well done, man. This was exactly what I meant. Thanks
Morph