Cell needs IF AND, with SUM of different cells to IF AND cells - Confused? I am

tammorice

New Member
Joined
Oct 13, 2015
Messages
23
Hi

I have a table where $M11=IF(AND($K$3="CASUAL",$F11<TIMEVALUE("02:00"),$F11>TIMEVALUE("00:00")),"02:00",$F11)

FILM
shift timebreakbreaktotal paid
118:300:300:157:45
121:452:00

<tbody>
</tbody>

K3 "CASUAL"

<tbody>
</tbody>

So all is good if the shift is less than 2hrs then the total paid is increased to 2hrs.

Any shift can be recorded on any row. so I need to be able to also deduct breaks from the total.

Can anyone guide me on how I can add the sum SUM(F11-I11-L11) to the formula above in M11:M50

Super appreciate your help.
 

Excel Facts

Format cells as time
Select range and press Ctrl+Shift+2 to format cells as time. (Shift 2 is the @ sign).
Im not entirely sure what you are after but perhaps try this:

=IF(AND($K$3="casual",F11>0),MAX(2/24,F11-I11-L11),0)
 
Upvote 0
Im not entirely sure what you are after but perhaps try this:

=IF(AND($K$3="casual",F11>0),MAX(2/24,F11-I11-L11),0)


Hey Steve the Fish, Thanks for such a quick response.

What I'm after is for these 2 formulas to calculate an answer in the one cell.

=IF(AND($K$3="CASUAL",$F11<TIMEVALUE("02:00"),$F11>TIMEVALUE("00:00")),"02:00",$F11)
=SUM(F11-I11-L11)


Row 11 is used for 2 different calcs.
1. a job (using drop down) with less than 2 hours (F11), that gets paid a minimum of 2hrs (M11), if more than 2 hours (F11), gets paid amount in F11.
2. a job (using drop down) with more than 2 hours (F11), that has breaks to be deducted (I11 and L11), that gets paid (shifthrs-breaks) (M11)

:confused:
 
Upvote 0
Hey Steve the Fish, Thanks for such a quick response.

What I'm after is for these 2 formulas to calculate an answer in the one cell.

=IF(AND($K$3="CASUAL",$F11<timevalue("02:00"),$f11>TIMEVALUE("00:00")),"02:00",$F11)
=SUM(F11-I11-L11)</timevalue("02:00"),$f11>


Row 11 is used for 2 different calcs.
1. a job (using drop down) with less than 2 hours (F11), that gets paid a minimum of 2hrs (M11), if more than 2 hours (F11), gets paid amount in F11.
2. a job (using drop down) with more than 2 hours (F11), that has breaks to be deducted (I11 and L11), that gets paid (shifthrs-breaks) (M11)

:confused:

I just realised my IF formula is wrong. oops

it should read:

=IF(AND($L$5="CASUAL",$F11<<timevalue("02:00"),$f11>TIMEVALUE("02:00"),$F11>TIMEVALUE("00:00")),"02:00",$F11)</timevalue("02:00"),$f11>
 
Last edited:
Upvote 0
Did you try what i suggested? Does that not do what you ask for?


No. Unfortunately, it returned "00:00".

It's time to have another look at this one (It was driving me crazy - so I backed away for a bit o_O) cause the basic vlookup i just did doesn't want to play either.
 
Upvote 0

Forum statistics

Threads
1,215,324
Messages
6,124,250
Members
449,149
Latest member
mwdbActuary

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