Browse by Tags
All Tags »
Validation (
RSS)
Back to Entity Framework Code First (EFCF) validation. On my previous post I mentioned that EFCF did not support fluent validation. While this is true, it isn’t too hard to implement one such mechanism, which is exactly why I am writing this! I will be...
Introduction Most persistence frameworks implement some kind of custom validation of entities before they are sent to the database. By custom I mean something more than just “is not null”, “has XX characters”, etc. This typically includes individual properties...
Since this blog started, back in 2008, I wrote a lot of posts. I’d say some are still up to date. I picked a few of them, those I’m more proud of, in no particular order. ASP.NET Web Forms: Using the ASP.NET Health Monitoring Provider to Secure Your Application...
OK, so let’s talk about validation. Most people are probably familiar with the out of the box validation attributes that MVC knows about, from the System.ComponentModel.DataAnnotations namespace, such as EnumDataTypeAttribute , RequiredAttribute , StringLengthAttribute...
The Data Annotations framework, introduced in .NET 3.5, and enhanced in .NET 4.0, is likely becoming the basis for attribute-based validation in .NET. I like about it the fact that it is extensible and that it can be (and indeed it is) used in a lot of...
I have talked before about server-side validation using the ASP.NET validation framework. A typical scenario would be, for example, to validate the existance of a given username, in a registration form. This time, I present here a much simpler way, which...
Entity Framework, LINQ to SQL and ASP.NET MVC support Microsoft's new validation API, which you can find on System.ComponentModel.DataAnnotations . It basically consists on attribute classes, inherited from System.ComponentModel.DataAnnotations.ValidationAttribute...
More Posts