time calculation on working hours less weekend

Heber

New Member
Joined
Oct 13, 2009
Messages
30
Hi I am Struggling to solve this!

I need to calculate time between two dates, but need to be only between 8:00 AM and 5:00 PM, excluding weekends.
I got some results, but when the start time is over 5:00 pm still add the time...
example below:

Start End Transmission time (h:mm)
28/09/2019 18:41 30/09/2019 9:29 ?

supposed to be only 1:29 min...

kind regards
Heber
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
Hi,

try this:


Book1
ABC
128-9-2019 18:41:0030-9-2019 09:29:001:29:00
Sheet1
Cell Formulas
RangeFormula
C1=(NETWORKDAYS(A1,B1)-1)*("17:00"-"08:00")+IF(NETWORKDAYS(B1,B1),MEDIAN(MOD(B1,1),"17:00","08:00"),"17:00")-MEDIAN(NETWORKDAYS(A1,A1)*MOD(A1,1),"17:00","08:00")
 
Upvote 0

Forum statistics

Threads
1,224,817
Messages
6,181,149
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top