The Gu provides an example of how you might create a custom validator that overrides RegularExpressionAttribute .
The advantage of this is that you don\'t have to cr
If u wanna a client validation, you should Register a server-side adapter for remote validation.
See here: http://msdn.microsoft.com/en-us/magazine/ee336030.aspx
and here: http://bradwilson.typepad.com/blog/2010/01/remote-validation-with-aspnet-mvc-2.html
Cracked it! Add the following to Global.asax.cs Application_Start()
DataAnnotationsModelValidatorProvider.RegisterAdapter(typeof(NameAttribute), typeof(RegularExpressionAttributeAdapter));