Lesson 1: Course Overview for Use Data Annotations in any C# Application

Published: 09 February 2024
on channel: Paul D. Sheriff
473
12

Lesson 1: Course Overview for Use Data Annotations in any C# Application
.NET Versions: This course applies to .NET 6, 7, and 8.

Quit writing code to validate your user input. In this course you are going to explore most of the data annotations supplied by Microsoft. You are going to develop a few custom validation attributes to check dates and numeric values. You also learn to create a custom validation attribute to compare the values between two different properties. This lesson provides you with an overview of what is in this course.

Content
Why Take my Course 00:00
Paul.Sheriff.About() 00:38
Software Versions Used in this Course 01:08
Who Should Take This Course 01:37
Course Objectives 02:05
Prerequisites 02:31
Course Outline 02:48
Labs 03:54

Course Outline
Course Overview for Data Annotations in C# Applications
Overview of .NET Data Annotations
A Sample of Using Data Annotations in C#
Validating Data Annotations Programmatically in C#
Adding the ErrorMessage Property to the [Required] Attribute
How the [Display] Attribute Changes the Error Message
The [MaxLength], [MinLength], and [StringLength] Attributes
Using the [Range] Attribute with Numeric and Date Data
Check Data Using the [RegularExpression] Annotation
[EmailAddress], [Phone], [Url], and [CreditCard] Annotations
Compare Two Property Values Using the [Compare] Attribute
Build Your Own Validation Using the [CustomValidation] Attribute
Custom Validations by Inheriting from the ValidationAttribute Class in C#
Create a Dynamic Date Range Validator in C#
Create a Custom [Compare] Validation Class in C#

Helpful Links
Samples and hands-on labs for this course: https://www.pdsa.com/YouTube

System.ComponentModel.DataAnnotations Namespace: 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


Watch video Lesson 1: Course Overview for Use Data Annotations in any C# Application online without registration, duration hours minute second in high quality. This video was added by user Paul D. Sheriff 09 February 2024, don't forget to share it with your friends and acquaintances, it has been viewed on our site 473 once and liked it 12 people.