Hi,
I am wondering if it is possible to make certain validation rules get executed in order but if one fails (error) then the next one not get executed.
For example:
public class MyViewModel
{
[MaxLength(10)]
[MinLength(15)]
public string description { get; set; }
}
In this particular case, the validation attributes does not make sense, but for illustration purposes lets say the length the field "description" is 11, I get 2 errors: maxlength and minlength. What I expect is that if maxlength fails the minlength does not get validated and I expect to get one single error.
Is this possible?
Thanks in advance and best regards,
Fabian