Adding up time from timestamps in excel

DerekWooley

New Member
Joined
May 1, 2018
Messages
34
Hello, I am trying to add up the total time differencebetween certain time stamps and when I do, I’m not sure how to convert thenumbers into hours for to get the correct sum. I have tried custom cellformatting but that doesn’t change the way excel sees inside the cell formulas.Below is the table I am using: it starts on Row 1, Column A. I am subtractingthe previous time from each time stamp except where it says “set-up” in columnB so my formula in Column D is on Row 4 is =IF(B5="",C5-C4,0). When Iadd all that up it should be 1.20 hours but when I sum it in excel, it shows.056. How do I get excel to calculate 1.20 hours?

[TABLE="width: 255"]
<tbody>[TR]
[TD="width: 81, bgcolor: transparent"]
Column A
[/TD]
[TD="width: 81, bgcolor: transparent"]
Column B
[/TD]
[TD="width: 81, bgcolor: transparent"]
Column C
[/TD]
[TD="width: 96, bgcolor: transparent"]
Column D
[/TD]
[/TR]
[TR]
[TD="width: 81"]
Part
[/TD]
[TD="width: 81"]
Type
[/TD]
[TD="width: 81"]
Time
[/TD]
[TD="width: 96"]
Inspection Time
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81"]
[/TD]
[TD="width: 81"]
Total
[/TD]
[TD="width: 96"]
0.05555556
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
13:30
[/TD]
[TD="width: 96, bgcolor: transparent"]
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
13:45
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:15
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
13:45
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:00
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
Set-up
[/TD]
[TD="width: 81, bgcolor: transparent"]
14:50
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:00
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
15:05
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:15
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
15:40
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:35
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
15:55
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:15
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
Set-up
[/TD]
[TD="width: 81, bgcolor: transparent"]
16:15
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:00
[/TD]
[/TR]
[TR]
[TD="width: 81, bgcolor: transparent"]
Part A
[/TD]
[TD="width: 81, bgcolor: transparent"]
[/TD]
[TD="width: 81, bgcolor: transparent"]
16:15
[/TD]
[TD="width: 96, bgcolor: transparent"]
0:00
[/TD]
[/TR]
</tbody>[/TABLE]

Thank you for any help!

 

Excel Facts

Which lookup functions find a value equal or greater than the lookup value?
MATCH uses -1 to find larger value (lookup table must be sorted ZA). XLOOKUP uses 1 to find values greater and does not need to be sorted.
Hi,

You just need to format your result cell (D1) as Time to show the sum the way you want.
 
Upvote 0
Ok so say I have 4 hours that I need to add the total from my table to. How do I convert the time differences from the time stamps to numbers so when I add the total of the differences it adds up to 5.20 (4 plus 1.20). Converting D1 to custom format h:mm only changed the way it appeared but not how it was added to the 4 hour general number; I still got 4.056 instead of 5.2.

FYI, I am pulling these time stamp differences into another table that has number of setup hours as numbers which can't be time format so I don't want to convert to time format. Maybe there is a formula that can be applied to the time stamp differences to make them more like numbers?
 
Last edited:
Upvote 0
I tried that but then on my other table I have a sumproduct formula that comes from these things that are machine counters that are not in time format but still indicate time differences add up to like 88 hours each instance. 4:00 ends up being .2 as a number.

I think what I am looking for is a formula like Value() but to work for time. For example, Change 0:15 to just 15, 0:35 to 35.
 
Last edited:
Upvote 0
If you want to Add 1 hour to an Actual Time Value of 1:20 (1 hour 20 minutes), you'll need to convert the 1 to Time Value, Not the other way around.
In Excel, 1 is 1 day, 2 is 2 days, 3 is 3 days, etc...

See below:


Book1
ABCDEF
1PartTypeTimeInspection TimeAdd 4 hours to D2
2Part ATotal1:20<-- format cell as Time or hh:mm5:20
3Part A13:30
4Part A13:450:15
5Part A13:450:00
6Part ASet-up14:500:00
7Part A15:050:15
8Part A15:400:35
9Part A15:550:15
10Part ASet-up16:150:00
11Part A16:150:00
Sheet306
Cell Formulas
RangeFormula
D2=SUM(D3:D11)
F2=4/24+D2
 
Upvote 0

Forum statistics

Threads
1,223,903
Messages
6,175,284
Members
452,630
Latest member
OdubiYouth

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top