I have the following class generated by EntityFramework,
public partial class Person
{
public string FirstName { get; set; }
public string Lastname { get; set; }
}
Now I would like to add custom Attributes before using it or modifying the above class dynamically using reflection. Something like below,
public partial class Person
{
[SomeCustomAttribute]
public string FirstName { get; set; }
[SomeCustomAttribute]
public string Lastname { get; set; }
}
Is it possible to add custom attributes using reflection?