Calculate diff. between 2 times

C

Connie Martin

I have followed "Help", but I'm not getting the right results, so something
is wrong.
In cell H8 I have the formula =NOW()
In cell K8 I typed 3-23 8:30 AM, formatted it as date and time, so it's
giving me 23-Mar-09 8:30 AM.
In cell K13 I have this formula: =K8-H8, and formatted the cell as "h:mm",
which is giving me 21:05 at the moment. Well, between now, which is 11:25 AM
3/20 and 8:30 AM 3/23 is almost 69 hours. Why is it giving me 21 hours??

Thank you
Connie
 
T

T. Valko

Format the formula cell as [h]:mm.

The brackets [ ] keep the hours from rolling over at 24 hours.

For example:

23:59, when that reaches 24:00 it rolls over to the next day and becomes
0:00.

47:59, when that reaches 48:00 it rolls over and becomes 0:00.

The brackets keep that from happening.
 
C

Connie Martin

Bingo! That's it! Thank you so much! Now I can get on with this
spreadsheet!!

Kind regards,
Connie

T. Valko said:
Format the formula cell as [h]:mm.

The brackets [ ] keep the hours from rolling over at 24 hours.

For example:

23:59, when that reaches 24:00 it rolls over to the next day and becomes
0:00.

47:59, when that reaches 48:00 it rolls over and becomes 0:00.

The brackets keep that from happening.

--
Biff
Microsoft Excel MVP


Connie Martin said:
I have followed "Help", but I'm not getting the right results, so something
is wrong.
In cell H8 I have the formula =NOW()
In cell K8 I typed 3-23 8:30 AM, formatted it as date and time, so it's
giving me 23-Mar-09 8:30 AM.
In cell K13 I have this formula: =K8-H8, and formatted the cell as "h:mm",
which is giving me 21:05 at the moment. Well, between now, which is 11:25
AM
3/20 and 8:30 AM 3/23 is almost 69 hours. Why is it giving me 21 hours??

Thank you
Connie
 
T

T. Valko

You're welcome!

Just to clarifiy...

At 24 hours the time rolls over and restarts at 0:

36:25

Would display as 12:25

48:15

Would display as 00:15.

--
Biff
Microsoft Excel MVP


Connie Martin said:
Bingo! That's it! Thank you so much! Now I can get on with this
spreadsheet!!

Kind regards,
Connie

T. Valko said:
Format the formula cell as [h]:mm.

The brackets [ ] keep the hours from rolling over at 24 hours.

For example:

23:59, when that reaches 24:00 it rolls over to the next day and becomes
0:00.

47:59, when that reaches 48:00 it rolls over and becomes 0:00.

The brackets keep that from happening.

--
Biff
Microsoft Excel MVP


Connie Martin said:
I have followed "Help", but I'm not getting the right results, so
something
is wrong.
In cell H8 I have the formula =NOW()
In cell K8 I typed 3-23 8:30 AM, formatted it as date and time, so it's
giving me 23-Mar-09 8:30 AM.
In cell K13 I have this formula: =K8-H8, and formatted the cell as
"h:mm",
which is giving me 21:05 at the moment. Well, between now, which is
11:25
AM
3/20 and 8:30 AM 3/23 is almost 69 hours. Why is it giving me 21
hours??

Thank you
Connie
 

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