Work out hours in different time slots

Lmaonade

Board Regular
Joined
Jan 5, 2018
Messages
52
Hi,

I want to create a tool in excel that will split a working shift depending on start and end time.

Book4
BCDEGHIJK
3FromTo
4Night Hours:20:0006:00Week dayWeek Night / SaturdaySunday / Bank Holiday
5
6StartEndBreakTotal
7Monday:13:4521:300.007.75
8Tuesday:00:0000:000.000.00
9Wednesday:07:4520:000.5011.75
10Thursday:19:0007:000.5011.50
11Friday:19:4507:451.0011.00
12Saturday:18:0004:000.759.25
13Sunday:19:4508:001.5010.75
14Bank Holiday:00:0000:000.000.00
Sheet1
Cell Formulas
RangeFormula
G7:G14G7=(F7*24)-E7


So you can see the night shift hours are 20:00 to 06:00. How would I create a rule in columns I, J and K to split each shift into how many hours should be in each section? Any breaks would be taken at 6 hours into the shift so that's where that would come off.

So row 7 (Monday) should split it as: 6.25 hours in Week day, 1.5 hours in Week Night / Saturday
row 13 (Sunday) should split it as 2 hours in week day (The 2 hours after 6am) 4.25hrs Sunday / Bank Holiday (The 19:45 to 00:00) and then 4.5 hours at Week Night Saturday (00:00 to 06:00 minus the break).

Saturday and Sunday rates are 00:00 to 00:00 (24 hours), Bank Holiday should be set the same way as Sunday, for example if someone works a Bank Holiday night - Anything after Midnight moves on to a normal week night rate until 06:00.

Hope this makes sense. If you need any more info please let me know and I really appreciate any help. :)

Thanks,
Andy
 

Excel Facts

Excel Can Read to You
Customize Quick Access Toolbar. From All Commands, add Speak Cells or Speak Cells on Enter to QAT. Select cells. Press Speak Cells.

Forum statistics

Threads
1,215,035
Messages
6,122,785
Members
449,095
Latest member
m_smith_solihull

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