title: Timespan in asp.net mvc application
body: <p>I'm writing an asp.net mvc app. in c#, and I'm wondering if anybody can help me to understand, if it's possible to display the time like 8:00 (without seconds) on the form in a dropdown list instead of 8:00:00. Thanks for your help!</p>
  
  <p>Right now I have a code in my timehepler.cs:</p>
  
  <pre><code>public static List&lt;TimeSpan&gt; TimeSpansInRange(TimeSpan start, TimeSpan end, TimeSpan interval)
          {
              List&lt;TimeSpan&gt; timeSpans = new List&lt;TimeSpan&gt;();
              while (start.Add(interval) &lt;= end)
              {
                  timeSpans.Add(start);
                  start = start.Add(interval);
              }
              return timeSpans;
          }
  
          public static List&lt;TimeSpan&gt; PossibleTimeSpansInDay()
          {
              return TimeSpansInRange(new TimeSpan(8, 0, 0), new TimeSpan(22, 30, 0), new TimeSpan(0, 30, 0));
          }
  </code></pre>