Lesson 12: Create Custom Validations by Inheriting from the ValidationAttribute Class

Опубликовано: 09 Февраль 2024
на канале: Paul D. Sheriff
124
5

Lesson 12: Create Custom Validations by Inheriting from the ValidationAttribute Class

In this lesson you learn about the ValidationAttribute class and how you use to build your own custom attribute classes. You create three classes to validate dates. One class validates a date is less than a maximum value specified in the attribute. One class validates a date is greater than a minimum value specified in the attribute. The last class passes in two integer values to specify how many years prior and in the future the date value entered must be within.

Content
Lesson Objectives 00:00
The ValidationAttribute Class 00:25
DEMO: Is Date Greater Than Minimum Date 00:50
DEMO: Is Date Less Than Maximum Date 05:58
DEMO: Check for a Minimum and Maximum Date 07:18
Lesson Summary 09:41

Useful Links
Samples and hands-on labs for this course: https://www.pdsa.com/YouTube
The ValidationAttribute Class: https://learn.microsoft.com/en-us/dot...

#dataannotation #validation #csharp #development #programming #dotnet #dotnetcore #dotnet6 #dotnet #dotnet8 #pauldsheriff #pluralsight #youtube

Paul.About()
Hello, my name is Paul D. Sheriff and I have a passion for teaching. I have been training developers for over 35 years through books, videos, article, blog posts, and international conferences and user groups.

Paul.Contact()
Website: https://www.pdsa.com
Email: [email protected]
LinkedIn:   / paulsheriff  
Blog: https://blogs.pdsa.com/
Pluralsight: https://app.pluralsight.com/profile/a...
YouTube Channel: @pauldsheriff


Смотрите видео Lesson 12: Create Custom Validations by Inheriting from the ValidationAttribute Class онлайн без регистрации, длительностью часов минут секунд в хорошем качестве. Это видео добавил пользователь Paul D. Sheriff 09 Февраль 2024, не забудьте поделиться им ссылкой с друзьями и знакомыми, на нашем сайте его посмотрели 124 раз и оно понравилось 5 людям.