I have an ASP.NET webform which I want to validate Client-Side and Server-Side, using the same validation controls. I can't seem to find the solution for this - the client validation works great, but when I disable javascript - It ignores the validation.
Help would much be appreciated.
Roman
Explicitly call Page.Validate() on the server side.
Or the overloaded Page.Validate(string) to target one of your validation groups.
Update:
I forgot, after you run Validate(..), check the Page.IsValid
property - it's up to you to stop the page from submitting if this property == false
.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With