Formula nesting?

C

Cat

I need the formula to come back with certain money when the cell above has a
certain number. This is the formula I have =IF(D5=2,3,0)(D5=2,3,0). If the
cell above has a 2 in it it should have $3 come back. If it has a 3 or
higher it should have $5 come back. If the cell is lower than 2 it should
have $0.
Please see example below:
C D E F G H
 
J

JLatham

Try this in D2 as the start
=IF(D1<2,0,IF(D1>=3,5,IF(D1=2,3,"undefined")))
The "undefined" is out there for any value between 2 and 3, such as 2.5.
 
L

Lars-Åke Aspelin

I need the formula to come back with certain money when the cell above has a
certain number. This is the formula I have =IF(D5=2,3,0)(D5=2,3,0). If the
cell above has a 2 in it it should have $3 come back. If it has a 3 or
higher it should have $5 come back. If the cell is lower than 2 it should
have $0.
Please see example below:
C D E F G H

Assuming that there are only integers in D5
you may try this formula:

=IF(D5<2,0,IF(D5=2,3,5))

Hope this helps / Lars-Åke
 
S

Sandy Mann

Try:

=IF(D6=2,2,IF(D6>2,5,0))

Or:

=(D6>1)*2+(D6>2)*3


--
HTH

Sandy
In Perth, the ancient capital of Scotland
and the crowning place of kings

(e-mail address removed)
Replace @mailinator.com with @tiscali.co.uk
 
C

Cat

IT WORKED! YOU ARE A ROCK STAR!!!
--
Thank you so much!


JLatham said:
Try this in D2 as the start
=IF(D1<2,0,IF(D1>=3,5,IF(D1=2,3,"undefined")))
The "undefined" is out there for any value between 2 and 3, such as 2.5.
 
J

JLatham

Looks like I wasn't the only one to provide a solution - just the quickest
one on the keyboard ---- this time.

Cat said:
IT WORKED! YOU ARE A ROCK STAR!!!
 

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