ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   how do i calculate time after midnite "01/12/05 13:00 to 01/13/05 (https://www.excelbanter.com/excel-discussion-misc-queries/10725-how-do-i-calculate-time-after-midnite-%2201-12-05-13-00-01-13-05-a.html)

highball

how do i calculate time after midnite "01/12/05 13:00 to 01/13/05
 
Example 01/12/05 13:00 to 01/13/05 02:00 should = 13 hours

problems with time

Arvi Laanemets

Hi

With Start date in A2 and end date in B2
=B2-A2+(B2<A2)
formatted as "hh:mm" or "h"

When you want the number of hours, then
=(B2-A2+(B2<A2))*24

--
When sending mail, use address arvil<attarkon.ee
Arvi Laanemets


"highball" wrote in message
...
Example 01/12/05 13:00 to 01/13/05 02:00 should = 13 hours

problems with time




RagDyeR

Start time in A1,
End time in B1,
Enter this formula in a cell formatted as "General" or "Number":

=(B1-A1+(B1<A1))*24*AND(A1<0,B1<0)

Both A1 and B1 must have times entered for this to work.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


"highball" wrote in message
...
Example 01/12/05 13:00 to 01/13/05 02:00 should = 13 hours

problems with time



highball

Works great thank Ragdyer.

"RagDyeR" wrote:

Start time in A1,
End time in B1,
Enter this formula in a cell formatted as "General" or "Number":

=(B1-A1+(B1<A1))*24*AND(A1<0,B1<0)

Both A1 and B1 must have times entered for this to work.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


"highball" wrote in message
...
Example 01/12/05 13:00 to 01/13/05 02:00 should = 13 hours

problems with time




RagDyeR

Appreciate the feed-back.
--

Regards,

RD
--------------------------------------------------------------------
Please keep all correspondence within the Group, so all may benefit !
--------------------------------------------------------------------

"highball" wrote in message
...
Works great thank Ragdyer.

"RagDyeR" wrote:

Start time in A1,
End time in B1,
Enter this formula in a cell formatted as "General" or "Number":

=(B1-A1+(B1<A1))*24*AND(A1<0,B1<0)

Both A1 and B1 must have times entered for this to work.
--

HTH,

RD
==============================================
Please keep all correspondence within the Group, so all may benefit!
==============================================


"highball" wrote in message
...
Example 01/12/05 13:00 to 01/13/05 02:00 should = 13 hours

problems with time







All times are GMT +1. The time now is 05:44 AM.

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