Stuck on this simple IF(AND formula

aedctalk

Board Regular
Joined
Oct 9, 2010
Messages
156
Hello, Below i have a formula i'm trying to use but its not working.

The first two formulas do work. However i need help with my last one.. I want it to display "yes for ones and 5's) if both of the first formulas are true.

So if d50<CONFIGJ19 < D49 & d50 both AND d49<configj21 and> to zero... then i want to display "yes for 1's & 5's"


How could i modify to do that?


=IF(AND(D50<Configuration!$J$19,D50>0),"YES FOR $5's",IF(AND(D49<Configuration!$J$21,D49>0),"YES FOR $1's",IF(AND(D49<Configuration!$J$21,D50<Configuration!$J$19),"YES FOR $1's & 5's","NO")))


Thanks for your help sooo much!
 
Last edited:

Excel Facts

What did Pito Salas invent?
Pito Salas, working for Lotus, popularized what would become to be pivot tables. It was released as Lotus Improv in 1989.
It looks like you may be using greater than/less than signs in your formula. Those often get interpretted as HTML characters, messing up your post. You can avoid that if you put spaces on either side of the greater than/less than signs or use code tags.

Regardless, it looks like your structure is wrong. Here is the structure of using IF with AND:

=IF(AND(condition 1, condition2, ...), what to return if true, what to return if false)
 
Upvote 0
Hello. Ok. Thank you. Here is my whole forumula

I'm still completely stuck. on how to make the last 1 & 5 part of formula work :(

Code:
=IF(AND(D50 < Configuration!$J$19,D50 > 0),"YES FOR $5's",IF(AND(D49 < Configuration!$J$21,D49 > 0),"YES FOR $1's",IF(AND(D49 < Configuration!$J$21,D50 < Configuration!$J$19),"YES FOR $1's & 5's","NO")))

Thanks for your help sooo much
 
Upvote 0
What are the values in each of your cells:
- D50
- D49
- Configuration!$J$19
- Configuration!$J$21

What is your expected result?

Understand that if you have a nested IF statement, once a one of the IF's is true, it will not evaluate any nested IF portions after that.

It might also be helpful if you could explain exactly how this formula should work, in relations to the cells you have mentioned. I am not sure how D49 relates to D50, etc.
 
Upvote 0
I believe that it is due to the logic of your statement. try this:

Code:
=IF(AND(D50 < Configuration!$J$19,D49 >= Configuration!$J$21,D50 > 0),"YES FOR $5's",IF(AND(D49 < Configuration!$J$21,D50 >= $J$19,D49 > 0),"YES FOR $1's",IF(AND(D49 < Configuration!$J$21,D50 < Configuration!$J$19),"YES FOR $1's & 5's","NO")))
 
Upvote 0

Forum statistics

Threads
1,224,534
Messages
6,179,391
Members
452,909
Latest member
VickiS

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