using System;
public class Program
{
public static void Main()
DateTime dt = new DateTime(2018,3,12);
if(dt.GetType()?.GetProperty("Day") != null) {
Console.WriteLine("We got the Day property");
Console.WriteLine(dt.GetType().GetProperty("Day"));
}