Help with Excel Formula

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!
 
B

Bill B

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...
 
J

Jan Karel Pieterse

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
 
C

C. Homey

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!
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top