title: Xamarin Forms Nullable Property - Object reference not set to an instance of an object
body: <p>I'm new to Xamarin Forms and trying to bind a nullable property in XAML  :</p>
  
  <pre><code> public DateTime? LocalExpiryDate  //property on Person class
      {
          get { return GetValue&lt;DateTime&gt;(); }
          set { SetValue(value); }
      }
  
   &lt;Label Text="{Binding LocalExpiryDate}"/&gt;
  </code></pre>
  
  <p>And binding in the code behind as:</p>
  
  <pre><code> InitializeComponent();
   MainStackLayout.BindingContext = member.Person;
  </code></pre>
  
  <p>Even though the property isn't null when I try and run the app on the Android Emulator I get an error "Exception has been thrown by the target of an invocation", and drilling down into the error I get a message "Object reference not set to an instance of an object"</p>
  
  <p>If I remove the ? to make the property not nullable then the app works fine as long as there is a property</p>
  
  <p>Is it not possible to bind to a nullable property or is there a way around this? </p>
  
  <p>Thanks</p>
  
  <p>Mark </p>