Hello rmhodson1 and Welcome to Excel Forum.
Wish that I could think of an easier way of accomplishing the goal, perhaps someone will be able to improve on this.
As modeled in the attached copy of the file G7:P7 is populated using the dates, G8:P9 is populated using shift times* and G10:P12 is populated using:
Formula:
=IF($D10>G$7+G$9,"",ROUND(MIN($C10-SUM($F10:F10),(G$9-G$8)*24,IF(F10="",(G$9-MOD($D10,1)),1)*24),2))
*The first shift (Tuesday - Friday) is shown as running from midnight through 16:00 then the second shift from 20:00 to midnight.
The 'End Date and Time' values are populated using:
Formula:
=MAX(INDEX(G10:P10,MATCH(0,G10:P10,0)-1)/24+INDEX(G$7:P$7,MATCH(0,G10:P10,0)-1)+INDEX(G$8:P$8,MATCH(0,G10:P10,0)-1),INDEX(G10:P10,MATCH(0,G10:P10,0)-1)/24+D10)
There may be a way to (semi) automate the populating of dates and times if the overall method is of any use to you.
Let us know if you have any questions.
Bookmarks