title: F# - Parse dates
body: <p>Very basic question regarding parsing date in F#. I am very new to F# and .NET, so please bear with me.</p>
  
  <p>My date has the format <code>yyyyMMDD</code> like <code>20100503</code>.</p>
  
  <p>How do I parse this into a <code>DateTime</code> type in F#.</p>
  
  <p>I tried <code>System.DateTime.Parse("20100503");</code> but get an error.</p>
  
  <p>How do I pass a format string into the Parse method?? </p>
  
  <p>ANSWER is - Thanks everyone for the responses.</p>
  
  <pre><code>let d = System.DateTime.ParseExact("20100503", "yyyyMMdd", System.Globalization.CultureInfo.InvariantCulture);
  </code></pre>