net no of hours bewtween tow dates

  • Thread starter Thread starter Kashif
  • Start date Start date
K

Kashif

I wanted to know net no of working hours between following two dates;

Time Start 23-Sep-2008 13:43
Time End 30-Sep-2008 18:24
Holiday 29-Sep-08


Kashif
 
Hi,

The answer depends on how long a day is. Is it 24 hours or limited to the
hours in your working day.

If a day is 24 hours long use this
=(NETWORKDAYS(A1,B1,Holidays)-1)+MOD(B1,1)-MOD(A1,1)

If a day is (say) 08:00 - 17:00 use this
=(NETWORKDAYS(A1,B1,Holidays)-1)*("17:00"-"08:00")+MOD(B1,1)-MOD(A1,1)

In both case the start time is in A1. End time in B1 and Holidays is a named
range that contains your holiday dates.

Format both as [hh]:mm

Mike
 
Back
Top