using System.Collections.Generic;
public static void Main()
Type t = typeof(MyClass);
var pi = t.GetProperty("MyProp");
Console.WriteLine("Property type ... {0}", pi);
Type answer = Nullable.GetUnderlyingType(pi);
Console.WriteLine("Underlying type ..... {0}", answer);
public int? MyProp { get; set; }