DateTime startDate = DateTime.Parse("17/06/2015 05:00:00 AM"); DateTime endDate = DateTime.Parse("19/06/2015 11:00:00 AM"); // Difference in days, hours, and minutes. TimeSpan ts = newDate - oldDate; //Format the TimeSpan as you see fit Console.WriteLine(ts.ToString());
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)