Nested If statement

J

Jock W

I need to write a nested 'if' stating something like this:
=IF((F5<1799),"87",IF(F5 between 1800and2499),116,170)
I am unsure of the between tis number and that number bit.

All help appreciated

tia
 
S

Sandy Mann

Jason Morin said:
=IF(F5<1799,87,IF(AND(F5>=1800,F5<=2499),116,170))

Contains the error, (if it is an error), in the OP's data where by 1799 is
treated as being greater than 2499 I am sure that you meant:

=IF(F5<=1799,87,IF(AND(F5>=1800,F5<=2499),116,170)) or

=IF(F5<1800,87,IF(AND(F5>=1800,F5<2500),116,170))

Jock W said:
Thanks Jason, job done

so, being as the OP did not ask for a blank cell if no data in F5, just for
fun:

=87+(F5>1799)*29+(F5>2499)*54

Regards

Sandy
 

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