Timesheet / Rosters issues - HELP

jayoharae

New Member
Joined
Nov 11, 2009
Messages
22
Dear all,

I am hoping someone can help resolved some issues with my spreadsheet.

So if D5=12:00PM and E5 = 12:00AM giving me a total of 12 hours

The formula i am using is
=IF(COUNT(D5:E5)=2,IF(MOD(E5-D5,1)*24<=5,MAX(0,ROUND((MOD(E5-D5,1)-30/1440)*24,2)),MOD(E5-TIME(1,0,0)-D5,1)*24),"")

This works a treat but if I could get it not to subtract any time if the rostered hours are less than 4 that would be awesome.
eg D5 = 6:00PM and E5 = 9:00PM it gives me a total of 2.5 hours.

Basically I need it to do the following:
rostered hours =<4 no break
" " >4 but <=9 minus 30mins
" " =>10 minus 1 hour

I have had a play around with it but I can't seem to figure out the correct way of doing this, any help would be fantastic

Jay
 

Excel Facts

What is the fastest way to copy a formula?
If A2:A50000 contain data. Enter a formula in B2. Select B2. Double-click the Fill Handle and Excel will shoot the formula down to B50000.

Forum statistics

Threads
1,223,214
Messages
6,170,774
Members
452,353
Latest member
strainu

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