Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15
Default Calculating Difference in Time (Amt. of Time Transpired)

Hello, and thank you in advance for help with this 'formula'. I am trying to
calculate the amount of time between two events. I am able to calculate if
the event times times fall within one calendar day; for example:
Event 1 11:35 AM Event 2 6:42 PM
Amount of Time = (6:42 PM) - (11:35 AM) = 7hr 7min
I am running into a problem when the second event takes place the following
day; for example:
Event 1 10:53 PM Event 2 3:41 AM
Amount of Time = (3:41 AM) - (10:53 PM) = (#VALUE!)
The result should be 4hr 48 min, but that is where I am stuck. Does anyone
know of a formula to perform this calculation when the second event occurs on
the following calendar? Any help will be greatly appreciated.
Thank You,
Dan Wollam
  #2   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 10,593
Default Calculating Difference in Time (Amt. of Time Transpired)

=MOD(A2-A1,1)

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"WOLLAM" wrote in message
...
Hello, and thank you in advance for help with this 'formula'. I am trying
to
calculate the amount of time between two events. I am able to calculate
if
the event times times fall within one calendar day; for example:
Event 1 11:35 AM Event 2 6:42 PM
Amount of Time = (6:42 PM) - (11:35 AM) = 7hr 7min
I am running into a problem when the second event takes place the
following
day; for example:
Event 1 10:53 PM Event 2 3:41 AM
Amount of Time = (3:41 AM) - (10:53 PM) = (#VALUE!)
The result should be 4hr 48 min, but that is where I am stuck. Does
anyone
know of a formula to perform this calculation when the second event occurs
on
the following calendar? Any help will be greatly appreciated.
Thank You,
Dan Wollam



  #3   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 63
Default Calculating Difference in Time (Amt. of Time Transpired)

If it only ever goes into the next day (not 2 or 3 days) then you can use

=IF(endtime<starttime,1+endtime-starttime,endtime-starttime)

(just substitute the cell references for the endtime and starttime cells).

Andrea Jones
www.stratatraining.co.uk
www.wrekinpublishing.com

"WOLLAM" wrote:

Hello, and thank you in advance for help with this 'formula'. I am trying to
calculate the amount of time between two events. I am able to calculate if
the event times times fall within one calendar day; for example:
Event 1 11:35 AM Event 2 6:42 PM
Amount of Time = (6:42 PM) - (11:35 AM) = 7hr 7min
I am running into a problem when the second event takes place the following
day; for example:
Event 1 10:53 PM Event 2 3:41 AM
Amount of Time = (3:41 AM) - (10:53 PM) = (#VALUE!)
The result should be 4hr 48 min, but that is where I am stuck. Does anyone
know of a formula to perform this calculation when the second event occurs on
the following calendar? Any help will be greatly appreciated.
Thank You,
Dan Wollam

  #4   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15
Default Calculating Difference in Time (Amt. of Time Transpired)

Thank you Andrea, I will try your suggestion, as well as Bob's to see which
better suits my needs. Thank you.

"Andrea Jones" wrote:

If it only ever goes into the next day (not 2 or 3 days) then you can use

=IF(endtime<starttime,1+endtime-starttime,endtime-starttime)

(just substitute the cell references for the endtime and starttime cells).

Andrea Jones
www.stratatraining.co.uk
www.wrekinpublishing.com

"WOLLAM" wrote:

Hello, and thank you in advance for help with this 'formula'. I am trying to
calculate the amount of time between two events. I am able to calculate if
the event times times fall within one calendar day; for example:
Event 1 11:35 AM Event 2 6:42 PM
Amount of Time = (6:42 PM) - (11:35 AM) = 7hr 7min
I am running into a problem when the second event takes place the following
day; for example:
Event 1 10:53 PM Event 2 3:41 AM
Amount of Time = (3:41 AM) - (10:53 PM) = (#VALUE!)
The result should be 4hr 48 min, but that is where I am stuck. Does anyone
know of a formula to perform this calculation when the second event occurs on
the following calendar? Any help will be greatly appreciated.
Thank You,
Dan Wollam

  #5   Report Post  
Posted to microsoft.public.excel.misc
external usenet poster
 
Posts: 15
Default Calculating Difference in Time (Amt. of Time Transpired)

Thank you Bob, I will try your suggestion, as well as Andrea's to see which
better suits my needs. Thank you.

"Bob Phillips" wrote:

=MOD(A2-A1,1)

--
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)

"WOLLAM" wrote in message
...
Hello, and thank you in advance for help with this 'formula'. I am trying
to
calculate the amount of time between two events. I am able to calculate
if
the event times times fall within one calendar day; for example:
Event 1 11:35 AM Event 2 6:42 PM
Amount of Time = (6:42 PM) - (11:35 AM) = 7hr 7min
I am running into a problem when the second event takes place the
following
day; for example:
Event 1 10:53 PM Event 2 3:41 AM
Amount of Time = (3:41 AM) - (10:53 PM) = (#VALUE!)
The result should be 4hr 48 min, but that is where I am stuck. Does
anyone
know of a formula to perform this calculation when the second event occurs
on
the following calendar? Any help will be greatly appreciated.
Thank You,
Dan Wollam




Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
calculating time difference Michel Khennafi Excel Worksheet Functions 1 January 31st 08 02:37 PM
calculating difference in time tam25 Excel Discussion (Misc queries) 4 September 7th 07 09:26 AM
Calculating time difference in minutes jonhunt Excel Worksheet Functions 7 July 3rd 06 03:49 PM
Calculating time difference over midnight! sygazelle Excel Discussion (Misc queries) 4 September 29th 05 04:59 PM
Calculating time difference Robyn Bellanger Excel Discussion (Misc queries) 2 December 23rd 04 02:29 AM


All times are GMT +1. The time now is 12:26 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"