title: How to get value of a Nullable Type via reflection
body: <p>Using reflection I need to retrieve the value of a propery of a <code>Nullable Type of DateTime</code></p>
  
  <p>How can I do this?</p>
  
  <p>When I try <code>propertyInfo.GetValue(object, null)</code> it does not function.</p>
  
  <p>thx</p>
  
  <p>My code:</p>
  
  <pre><code> var propertyInfos = myClass.GetType().GetProperties();
  
   foreach (PropertyInfo propertyInfo in propertyInfos)
   {
       object propertyValue= propertyInfo.GetValue(myClass, null);
   }
  </code></pre>
  
  <p>propertyValue result always null for nullable type</p>