Calculating date and time events


Posted by Mike on December 31, 2001 6:56 AM

have not been successful getting excel to calculate the time between two events. example 12/31/2001 15:00:00 to 1/1/2002 15:01:00 is 24 hrs 1 min. Is there a function that I have not seen in "HELP"?



Posted by Barrie Davidson on December 31, 2001 7:29 AM

Mike, all you need to do is subtract the two and format the result to display hours and minutes. If you place the first date in cell A1, the second date in cell B1, the formula "=B1-A1" in cell C1, and custom format cell C1 to display hours and minutes, the result will be 24:01. To custom format, select Format|Cells from the main menu. Then, on the "Number" tab, select "Custom". In the "Type" box, type in

[h]:mm

This will display hours and minutes.

Hope this helps,
BarrieBarrie Davidson