title: Formatting nullable DateTime fields in strong typed View
body: <p>I have a Person class with a BornDate property in my model defined as </p>
  
  <pre><code>[DisplayName("Born Date")]
  public DateTime? BornDate { get; set; }
  </code></pre>
  
  <p>I use this field in my view as</p>
  
  <pre><code>&lt;td style="white-space:nowrap"&gt;
      &lt;%= Html.LabelFor(model =&gt; model.BornDate)%&gt;
      &lt;br /&gt;
      &lt;%= Html.TextBoxFor(model =&gt; model.BornDate, new { id = "bornDate" })%&gt;
      &lt;%= Html.ValidationMessageFor(model =&gt; model.BornDate, "*")%&gt;
  &lt;/td&gt;
  </code></pre>
  
  <p>The problem is that when I am editing a Person instance with the BornDate text box is formatted as </p>
  
  <pre><code>dd/MM/yyyy hh.mm.ss
  </code></pre>
  
  <p>while I would like to format it without the time part ("dd/MM/yyyy"). I am not able to use the toString method with the format string because it is a nullable field. </p>
  
  <p>what can I do?</p>