title: Empty String to Double using (Try)Parse
body: <p>I've got a with 1.1 build system here using Parse for converting values (now it's 3.5).</p>
  
  <pre><code>string myString = String.Empty;
  double myValue = double.Parse(myString);
  </code></pre>
  
  <p>throws a FormatException (I expected 0.0).</p>
  
  <p>If I rewrite that using 2.0+</p>
  
  <pre><code>string myString = String.Empty;
  double myValue;
  if (double.TryParse(myString, out myValue))
      //do something
  </code></pre>
  
  <p>I get the wanted 0.0, but unfortunately I lose the possibility to get a meaningful error message (in the else tree).</p>
  
  <p>Why is giving me Parse an error and TryParse my expected value?
  Is there any way to get the error message out of TryParse (time is not the problem)?</p>
  
  <p>I don't want to work around it like that:</p>
  
  <ul>
  <li><p>Avoid the error using if...then</p>
  
  <pre><code>myValue = myString.Length == 0 ? 0.0 : double.Parse(myString);
  </code></pre></li>
  <li><p>Two Calls if an error occured</p>
  
  <pre><code>if (!double.TryParse(myString, out myValue))
      myValue = double.Parse(myString);
  </code></pre></li>
  </ul>