Formula for adding hours worked from one start time to another (am/pm)

Copper Contributor

First time user of the community. Probably a very simple question but, how do I caculate the total hours when, in Cell #1 I have the start time (e.g. 8:00 am) and the other cell I have the end time (5 pm.)?

6 Replies

@Northwest_Plumbing 

That's = endTime - startTime

assuming both are for the same day

@Sergei Baklan 

Thank you, I tried that and here is the result: 

Time InBreaksTime OutHours
8:00:00 AM0.506:00:00 PM-0.42

It should total: 10 hrs??

@Northwest_Plumbing , change the number format to "hh" to get the time in hours. 

@TheAntony 

Thank you Anthony. That helped to make it look better but, I still haven't found a formula to add the hours from start time to end time?

@Northwest_Plumbing 

Operate with time as with any numbers. Actually in Excel days are equivalent of integer numbers where 1 is Jan 01, 1900 and time is decimal part of the number where 1 hour is equal to 1/24.

 

Just apply time format to the result and take into account time could not be negative.

@Northwest_Plumbing 

 

even if the solution of the others are more elegant .. I send my small solution for quick processing :)

sry in advance for my additional intervention

 

If you have solved your problem with this solution, please mark it as the correct answer so that others can also get this information.
If this is not what you are looking for, please give us a quick feedback.

 

 

Nikolino
I know I don't know anything (Socrates)