Reg Hr, OT and DT

ThaiThao

New Member
Joined
Feb 24, 2023
Messages
2
Office Version
  1. 2021
Platform
  1. Windows
How would I go about calculating reg hours, OT and DT with set rules? What I made isn't taking into account 2pm through 10pm. It's just calculating the amount of hours I have. So say for example, I clock in at 6pm and clocked out at 2am. I want reg hours = 4, OT = 2, DT = 2
Reg Hours = 2pm to 10 pm
OT = 10pm - 12am
DT = 12am+
Pay Calculator.xlsm
BCDEFGHIJKLMNO
9Day of the Week↓Clocked In↓Clocked Out↓Reg HRs Worked↓OT Hours↓DT Hours↓Total Daily Hours↓
10Monday6:00 PM2:00 AM8.000.000.008.00
11Tuesday2:00 PM10:00 PM8.000.000.008.00
12Wednesday2:00 PM10:00 PM8.000.000.008.00
13Thursday2:00 PM10:00 PM8.000.000.008.00
14Friday2:00 PM10:00 PM8.000.000.008.00
15Saturday0.000.000.00
16Sunday0.000.00
Sheet1
Cell Formulas
RangeFormula
L10:L14L10=IF((F10-D10+(F10<D10))*24>10,(F10-D10+(F10<D10))*24-10,0)
N10:N14N10=SUM(H10:M10)
L15L15=IF((F15-D15+(F15<D15))*24>8,(F15-D15+(F15<D15))*24-8,0)
N15N15=SUM(J15:M15)
L16L16=IF((F16-D16+(F16<D16))*24>0,(F16-D16+(F16<D16))*24,0)
N16N16=SUM(L16)
H10:H14H10=MIN(8,IF((F10-D10+(F10<D10))*24>1,(F10-D10+(F10<D10))*24, 0))
J10:J14J10=MIN(2,IF((F10-D10+(F10<D10))*24>8,(F10-D10+(F10<D10))*24-8,0))
J15J15=MIN(8,IF((F15-D15+(F15<D15))*24>0,(F15-D15+(F15<D15))*24,0))
 

Excel Facts

When they said...
When they said you are going to "Excel at life", they meant you "will be doing Excel your whole life".
I could not figure out your formulas. Not saying they are wrong, but just couldn't figure them out. Maybe you will not understand mine1
but try this:

mr excel 9.xlsm
ABCDEFGHIJKLMN
1Day of the Week↓Clocked In↓Clocked Out↓Reg HRs Worked↓SuggestionOT Hours↓SuggestionDT Hours↓SuggestionTotal Daily Hours↓Suggestion
2Monday18:00:0002:00:00004:00:00002:00:00002:00:00008:00:00
3Tuesday14:00:0022:00:00008:00:00000:00:00000:00:00008:00:00
4Wednesday14:00:0022:00:00008:00:00000:00:00000:00:00008:00:00
5Thursday14:00:0022:00:00008:00:00000:00:00000:00:00008:00:00
6Friday14:00:0022:00:00008:00:00000:00:00000:00:00008:00:00
7Saturday00:00:00000:00:00000:00:00000:00:00
8Sunday00:00:0000:00:00000:00:00000:00:00
Sheet8
Cell Formulas
RangeFormula
J2:J8J2=IF(IF(E2<C2,E2+1,E2)>TIME(22,0,0),MIN(1-TIME(22,0,0),ABS(E2-TIME(22,0,0))),0)
K2:K6K2=IF((F10-D10+(F10<D10))*24>10,(F10-D10+(F10<D10))*24-10,0)
L2:L8L2=IF(E2<C2,E2,0)
M2:M6M2=SUM(H10:M10)
N2:N8N2=SUM(H2,J2,L2)
K7K7=IF((F15-D15+(F15<D15))*24>8,(F15-D15+(F15<D15))*24-8,0)
M7M7=SUM(J15:M15)
K8K8=IF((F16-D16+(F16<D16))*24>0,(F16-D16+(F16<D16))*24,0)
M8M8=SUM(L16)
G2:G6G2=MIN(8,IF((F10-D10+(F10<D10))*24>1,(F10-D10+(F10<D10))*24, 0))
I2:I6I2=MIN(2,IF((F10-D10+(F10<D10))*24>8,(F10-D10+(F10<D10))*24-8,0))
I7I7=MIN(8,IF((F15-D15+(F15<D15))*24>0,(F15-D15+(F15<D15))*24,0))
H2:H8H2=MIN(TIME(22,0,0)-C2,ABS(E2-C2))
 
Upvote 0
I could not figure out your formulas. Not saying they are wrong, but just couldn't figure them out. Maybe you will not understand mine1
but try this:
Thanks for the reply, it work handsomely. You did it way better and more simple than I could've thought of, lol.
Now, what if I worked from 12pm to 2am? Reg Hrs = 8, OT = 4, DT = 2
Reg Hours = 2pm to 10 pm
OT = 10pm - 12am (Post Shift OT), 12pm - 2pm(Pre Shift OT)
DT = 12am+
(sorry I added to my OP, didn't think about this until i tried your formula)
 
Upvote 0
it probably will not work as the formulas i gave have hard cutoffs for the start of OT. I was only going with OT starting at 10 pm, not after 8 hours was spent.
 
Upvote 0

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