Time and Date task scheduling for a 2 shift operation

woodypen

New Member
Joined
Feb 21, 2019
Messages
1
This is a small part of a larger project. I am not a VBA person so please keep that in mind.

I am trying to develop a task level schedule planner for a 2 shift 10 hour per shift operation. I have a list of task with start date, duration and a calculated end date based on the duration. All task are sequential for this example. There are 2 problems. 1) How to deal with the 4 hours of non-work time? and 2) How to deal with duration's longer than 20 hours?

For the first problem I created the following to calculate the task end time. It works for problem 1 but is kind of a long formula. Any suggestions to simplify it?

A13 = start date
B13 = Duration in hours
B10 = 2nd shift end time
B6 = 1st shift start time

=IF(AND(A13+B13/24-TRUNC(A13+B13/24,0)>$B$10,A13+B13/24-TRUNC(A13+B13/24,0)<$B$7),A13+B13/24+4/24,A13+B13/24)

For problem 2 I am having problems dealing with any duration greater than a workday of 20 hours. My thought is that for every increment of 20 hours I would add 4 hours (20 to 40 add 4 hrs, 40 to 80 add 8 hrs, etc.) to the calculated end time as long as the calculated task end time is not during the non-work time. Any suggestions on how to tackle this problem?

After I get this solved it's time to add non-work days (holidays, weekends). Did I mention that this tool will be used globally with variable holiday, weekends and other local work rules. The fun is only beginning. :)
 

Excel Facts

Square and cube roots
The =SQRT(25) is a square root. For a cube root, use =125^(1/3). For a fourth root, use =625^(1/4).

Forum statistics

Threads
1,214,881
Messages
6,122,074
Members
449,064
Latest member
MattDRT

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