ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Compute time differences (https://www.excelbanter.com/excel-programming/454022-compute-time-differences.html)

GARYWC

Compute time differences
 
What formula will compute the number of hours and minutes between the Start Time and the End time in each row?

(Each cell is formatted as number, custom, type: h:mm AM/PM)

Start time End time
12:45 PM 3:14 PM
10:20 AM 12:10 PM
10:20 AM 12:30 PM
9:30 AM 11:30 AM
10:00 AM 12:24 PM
11:20 AM 1:40 PM
11:27 AM 1:42 PM
1:35 PM 3:51 PM
10:30 AM 12:38 PM
11:55 AM 2:05 PM
10:05 AM 12:00 PM
12:00 PM 2:10 PM
10:00 AM 12:50 PM
11:55 AM 1:40 PM
12:45 PM 2:58 PM
12:45 PM 3:13 PM

Auric__

Compute time differences
 
GARYWC wrote:

What formula will compute the number of hours and minutes between the Start
Time and the End time in each row?

(Each cell is formatted as number, custom, type: h:mm AM/PM)


Just "=B2-A2" and format the destination cells as time without AM/PM.

--
Kneel! Bow!

GS[_6_]

Compute time differences
 
GARYWC wrote:

What formula will compute the number of hours and minutes between the Start
Time and the End time in each row?

(Each cell is formatted as number, custom, type: h:mm AM/PM)


Just "=B2-A2" and format the destination cells as time without AM/PM.


That only works so long as the time values aren't PM start to AM End.

--
Garry

Free usenet access at http://www.eternal-september.org
Classic VB Users Regroup!
comp.lang.basic.visual.misc
microsoft.public.vb.general.discussion

DeBosuil

Compute time differences
 
In reply to "GARYWC" who wrote the following:

What formula will compute the number of hours and minutes between the Start
Time and the End time in each row?

(Each cell is formatted as number, custom, type: h:mm AM/PM)

Use formule(A2B2)+B2-A1)

Cel set hh:mm
Use no PM/AM but 24 hours

Regards



--
--------------------------------- --- -- -
Posted with NewsLeecher v7.0 Beta 10
Web @ http://www.newsleecher.com/?usenet
------------------- ----- ---- -- -


DeBosuil

Compute time differences
 

What formula will compute the number of hours and minutes between the Start
Time and the End time in each row?

(Each cell is formatted as number, custom, type: h:mm AM/PM)

Excuse for mistyping in the first respose.

Use formule(A2B2)+B2-A2

Cel set hh:mm
Use no PM/AM but 24 hours

Regards



--
--------------------------------- --- -- -
Posted with NewsLeecher v7.0 Beta 10
Web @ http://www.newsleecher.com/?usenet
------------------- ----- ---- -- -



All times are GMT +1. The time now is 02:42 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com