Caluculate difference between two times
assuming that neither of your start or end date/times will fall between 11 PM
Friday and 11 PM Sunday you can use this formula
=(NETWORKDAYS(A1+"1:00",B1+"1:00")-1+MOD(B1+"1:00",1)-MOD(A1+"1:00",1))*24
note: NETWORKDAYS is part of Analysis ToolPak. If you get #NAME! error with
the above then you need to install. Tools addins tick "Analysis ToolPak"
"BRO" wrote:
I am looking for a formula to calculate the difference between two times in
hours. I also want to exclude the time between 11 PM on Friday night and 11
PM on Sunday night.
Example
Time 2: 1/23/07 8:31 (B1)
Time 1: 1/19/07 13:52 (A1)
Difference is 90.7 hrs
Excluding weekend hrs difference would be 42.7 hrs
--
BRO
|