Help with Excel Formula

  • Thread starter Thread starter C. Homey
  • Start date Start date
C

C. Homey

I want to write a formula that checks for two conditions:

If (A2 < 2,000 AND B2 = 500,A2*5,B2*5)

or a range:

If (A2 is >95 and/but < 200,"My text","more text")


I would GREATLY appreciate any help on this!

Thank you!
 
Hi homey,
Excel doesn't use 'and' 'or' or 'buts' per se. Instead
you have to implement logical constructions such as 'and'
using nested if statements. Suppose you wanted to
calculate the first function you mentioned below:

=if(A2<2000,if(B2=500,A2*5,B2*5),B2*5)
ugly but it works...

btw this place is for crashes and other disasters, try
using New Users or Worksheet Functions...
 
Hi C.,
I want to write a formula that checks for two conditions:

If (A2 < 2,000 AND B2 = 500,A2*5,B2*5)

Bill's formula is correct, but Excel DOES have AND:

=If(AND(A2<2000,B2=500),A2*5,B2*5)

Regards,

Jan Karel Pieterse
Excel MVP
www.jkp-ads.com
 
Thank you Bill and Jan for your assistance! And I apologize for the
misplacement of my question - I wondered what "crashesgpf" meant..."
Anyway, both solutions are great - I incorporated Jan's suggestion
because it is easier to read - and the result is exactly what I
needed!!

Without the help of people like you, I really don't know what the rest
of us would do. ;o)

Thanks again!
 
Back
Top