Install the FluentValidation .NET library for validation. Below is our sample Contact class and its corresponding validator class. The validator class needs to inherit AbstractValidator<Contact> and define the validation rules in the constructor using the RuleFor method. Instantiate the validator class, and pass the object to be validated. Here we have passed incorrect values for … Continue…
Continue Reading Nishant Rana’s Article on their blog
FluentValidation – build strongly-typed validation rules in .NET
Install the FluentValidation .NET library for validation. Below is our sample Contact class and its corresponding validator class. The validator class needs to inherit AbstractValidator and define the validation rules in the constructor using the RuleFor method. Instantiate the validator class, and pass the object to be validated.
Blog Syndicated with Nishant Rana’s Permission
More About This Author
Array
- Dyn365CE22 April 2024Versioning and Drafts for Solution-based Cloud Flows – Power Automate
- Dyn365CE16 April 2024What will happen on changing the password of the user account used as the Owner of Cloud Flow and for Connection – Power Automate
- Dyn365CE15 April 2024Using Focused view in Dynamics 365
- Dyn365CE9 April 2024Associate activities (Email) with multiple related records – Dataverse / Dynamics 365