NESTED iF STATEMENT

ruplekar

New Member
Joined
Jul 17, 2017
Messages
6
HI, help on below if statement> i am getting " you have entered too many arguments" message.

=IF(AND($J$12>=A20,$A20>$I$12,$J$12>A19),(LOOKUP(I20,'CLICK CHARGES'!$N$3:$O$10,'CLICK CHARGES'!$Q$3:$Q$10*I20)),IF(AND($M$12>=A20,$L$12>$J$12),LOOKUP(I20,'CLICK CHARGES'!$N$14:$O$21,'CLICK CHARGES'!$Q$14:$Q$21*I20)),IF(AND(O12>L12,O12>M12),LOOKUP(I20,'CLICK CHARGES'!N25:O32,'CLICK CHARGES'!Q25:Q32*I20),0))
 

Excel Facts

Get help while writing formula
Click the italics "fx" icon to the left of the formula bar to open the Functions Arguments dialog. Help is displayed for each argument.
HI, help on below if statement> i am getting " you have entered too many arguments" message.

=IF(AND($J$12>=A20,$A20>$I$12,$J$12>A19),(LOOKUP(I20,'CLICK CHARGES'!$N$3:$O$10,'CLICK CHARGES'!$Q$3:$Q$10*I20)),IF(AND($M$12>=A20,$L$12>$J$12),LOOKUP(I20,'CLICK CHARGES'!$N$14:$O$21,'CLICK CHARGES'!$Q$14:$Q$21*I20)),IF(AND(O12>L12,O12>M12),LOOKUP(I20,'CLICK CHARGES'!N25:O32,'CLICK CHARGES'!Q25:Q32*I20),0))

Try the following:
=IF(AND($J$12>=A20,$A20>$I$12,$J$12>A19),(LOOKUP(I20,'CLICK CHARGES'!$N$3:$O$10,'CLICK CHARGES'!$Q$3:$Q$10*I20)),IF(AND($M$12>=A20,$L$12>$J$12),LOOKUP(I20,'CLICK CHARGES'!$N$14:$O$21,'CLICK CHARGES'!$Q$14:$Q$21*I20),IF(AND(O12>L12,O12>M12),LOOKUP(I20,'CLICK CHARGES'!N25:O32,'CLICK CHARGES'!Q25:Q32*I20),0)))

The last if statement did not get in. I moved a parentheses to the outside.
 
Upvote 0

Forum statistics

Threads
1,224,824
Messages
6,181,187
Members
453,020
Latest member
Mohamed Magdi Tawfiq Emam

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