views:

438

answers:

1

This is a two part question.

  1. Is it possible to take advantage of xVal's automatic client side validation with ASP.NET WebForms?
  2. If so, are there any examples available?

I imagine that it would be possible to extend xVal to include ASP.NET Validator controls. These controls would be the WebForms equivalent of <%= Html.ClientSideValidation() %> for MVC. But before I dive in too deep, I wanted to see if anyone else has tried this. (And yes I did try Google, but the results weren't very helpful.)

+3  A: 

From the xVal CodePlex forum:

I think it should be possible to adapt xVal to work with ASP.NET WebForms. However to keep the xVal project focused, I don't want to try adding that support and would rather make the MVC experience as streamlined as possible.

Feel free to have a go yourself though!

-- Steve Sanderson, xVal cooridinator

So when I have some time, I'll see if I can't modify the xVal source to work with WebForms.

Update: I've created xVal.WebForms, a CodePlex project for this. See my blog post for details.

jrummell
It is possible: http://john.rummell.info/john/blog/post/xVal-with-WebForms.aspx
jrummell
I'm not using WebForms but this post has helped me integrate xVal into my own custom web server. Thanks for the post!
chakrit