Hi,
I kindly ask all you experts to help me calculate working hours inside the following hours:
MON-FRI 8:00AM-6:00PM and on SAT 8:00AM-1:00PM, SUN closed
The formula must not calculate times outside the working hours.
I have try following formula, but it also calculates SUNDAYS. Anyone knows how to modify this formula to exclude SUNDAYS?
=SUM(INT((WEEKDAY(E4-{0;1})+INT(E5)-INT(E4))/7)*($V$7-$U$7);INT((WEEKDAY(E4-{2;3;4;5;6})+INT(E5)-INT(E4))/7)*($T$7-$S$7))-IF(WEEKDAY(E4;2)>5;MEDIAN(0;MOD(E4;1)-$U$7;$V$7-$U$7);MEDIAN(0;MOD(E4;1)-$S$7;$T$7-$S$7))-IF(WEEKDAY(E5;2)>5;MEDIAN(0;$V$7-MOD(E5;1);$V$7-$U$7);MEDIAN(0;$T$7-MOD(E5;1);$T$7-$S$7))
Where:
E4 - START WORKING DATE & TIME
E5 - STOP WORKING DATE & TIME
S7 - SHOP OPENING HOURS [MON-FRI]
T7 - SHOP CLOSING HOURS [MON-FRI]
U7 - SHOP OPENING HOURS [SAT]
V7 - SHOP CLOSING HOURS [SAT]
Thanks & Regards
miki12
Bookmarks