[Solved] how to calculate time difference in excel working hours only
You will need a helper column with this formula: =24*(SUMPRODUCT((TEXT(ROW(INDEX(AAA:AAA,$F$1):INDEX(AAA:AAA,$F$2)),”dddd”)=A1)*(C1-B1))-IF(TEXT($F$1,”dddd”)=A1,MOD($F$1,1)-B1,0)-IF(TEXT($F$2,”dddd”)=A1,C1-MOD($F$2,1),0)) Then sum that column. Here it is in one formula using NETWORKDAYS.INTL =IF(DATEDIF(F1,F2,”d”)>1,NETWORKDAYS.INTL(F1+1,F2-1,”0000011″)*12+NETWORKDAYS.INTL(F1+1,F2-1,”1111101″)*4,0)+IF(DATEDIF(F1,F2,”d”)>0,(MOD(F2,1)-IF(WEEKDAY(F2,2)<6,TIME(7,0,0),TIME(9,0,0)))*24+(IF(WEEKDAY(F1,2)<6,TIME(19,0,0),TIME(13,0,0))-MOD(F1,1))*24,(F2-F1)*24) 4 solved how to calculate time difference in excel working hours only