given:
public class Customer
{
public int Id { get; set; }
public string FirstName { get; set; }
public DateTime Birthdate { get; set; }
}
I have List where some birthdates weren’t entered and so when I bind to GridView it shows DateTime.MinValue. What are some different ways to show a blank in a gridview if the birthdate is DateTime.MinValue?
Unless that’s mapped to a Database, I’d make it nullable:
EDIT:
If it IS mapped, then I’d just make a readonly nullable value for it: