© 2026 Hedgehog Software, LLC
Twitter
GitHub
Discord
System
Light
Dark
More
Communities
Docs
About
Terms
Privacy
Search
Star
Feedback
Setup for Free
C
C#
•
4y ago
•
5 replies
Dreams
Why does this code have a Required attribute?
It uses the same
System.ComponentModel.DataAnnotations
System.ComponentModel.DataAnnotations
as the Models in the folder above it
, but this isn
't a Entity Framework Model
https://github.com/PacktPublishing/ASP.NET-Core-6-and-Angular/blob/main/Chapter_13/WorldCities/WorldCitiesAPI/Data/LoginRequest.cs
GitHub
ASP.NET-Core-6-and-Angular/LoginRequest.cs at main · PacktPublishin...
ASP
.NET
-Core
-6
-and
-Angular
, published by Packt
. Contribute to PacktPublishing
/ASP
.NET
-Core
-6
-and
-Angular development by creating an account on GitHub
.
C#
Join
We are a programming server aimed at coders discussing everything related to C# (CSharp) and .NET.
61,871
Members
View on Discord
Resources
ModelContextProtocol
ModelContextProtocol
MCP Server
Similar Threads
Was this page helpful?
Yes
No
Recent Announcements
Similar Threads
✅ required attribute vs [Required] annotation
C
C# / help
12mo ago
❔ Does Required attribute work for controller parameters?
C
C# / help
4y ago
why does this code not work???
C
C# / help
3w ago
❔ Why does this code always return False?
C
C# / help
3y ago