First of all, your code won't even compile. You need to use double quotes for strings, not single quotes.
DateTime date1 = Convert.ToDateTime("2015/06/20");
DateTime date2 = Convert.ToDateTime("2015/05/20");
By the way, what you see (as a format) on TimeSpan latetime = date1.Subtract(date2);
line is probably just a debugger representation. A TimeSpan
doesn't have any implicit format itself. Formatting concept only will be an issue when you try get it's textual representation.
And TimeSpan
formatting is little bit different than DateTime
formatting. You can use hh\\:mm
format like;
string value = latetime.ToString("hh\\:mm");
or you can use verbatim string literal;
string value = latetime.ToString(@"hh\:mm");