Subtracting Time

K

Kris

Here is the scenario.

If I had a cell that had 8:00 formated in time (h:mm). I wanted to subtract
1 from it to get an answer of 7:00, what would I need to do.

or lets say I had 8:00 and wanted to subtract .5, to return 7:30, what would
I need to do.
 
J

John C

Time is stored as a fractional number in excel. 1 Hour = 1/24, so, if you
just wanted to be able to type a 1 or a 0.5 to subtract that from 1 actual
time to get another actual time, you would want to /24 to get it right.
A1: 8:00 AM
B1: 1 .... time to subtract, in hours
C1: =A1-B1/24
You could also use the TIME function as an alternative:
C1: =A1-TIME(B1,0,0)

Be aware, if you are just using time, and you try to subtract a time to
before midnight (i.e.: B1 above >8), then you might wanna switch to the 1904
date system to avoid the ##################### response.
 
S

Sheeloo

If you have the time 8:00 in A1 then use this

=A1-TIME(1,0,0) to subtract one hour...
Second parameter (first 0) represent minutes and third seconds...

=A1-TIME(0,30,0) to subtract half an hour...
 
M

muddan madhu

try this

start time - 8.00 AM in cell A1
end time - 5:00 PM in cell B1
Break - 1 - in cell C1

in D1 put this formula

=(B1-A1)-(C1/24)
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top