title: How to fix 'Input string was not in a correct format.' when using TimeSpan.ToString()?
body: <p>I have a program that manages clients arrival, and whenever a new client is created, the <code>TimeSpan</code> property <code>TimeOfArrival</code> is assigned the current time of day with :</p>
  
  <pre class="lang-cs prettyprint-override"><code>TimeSpan TimeOfArrival = DateTime.Now.TimeOfDay;
  </code></pre>
  
  <p>Now I'm trying to put that in a more convenient format that way :</p>
  
  <pre class="lang-cs prettyprint-override"><code>string ShortTime = TimeOfArrival.ToString("hh:mm");
  </code></pre>
  
  <p>Though now I get the following exception :</p>
  
  <blockquote>
    <p>System.FormatException: 'Input string was not in a correct format.'</p>
  </blockquote>
  
  <p>I can't seem to understand what the problem is. I checked and TimeOfArrival actually has a correct TimeSpan value right before I get the exception. That exception wouldn't surprise me if I was trying to parse an user input into a TimeSpan, but there I'm confused. Could anyone help ?
  Thanks in advance</p>