How can i create a IF function to make value1 = 3500 and value 2 = 500 and so on, in a single cell?


Posted by Tim Dawe Gold-Dragon-Imaginations on December 13, 2000 5:05 PM

Well im trying to get a cell to check another cell and check the contents IE 0-15 and set a price for the diffrent values in another cell.

I was wondering if it can be done with the IF function.?
please help.
Tim



Posted by Tim Francis-Wright on December 13, 2000 7:41 PM

I think that the CHOOSE function does what you
want:

=CHOOSE(B1,3500,500,100,50) will return 3500 if
B1=1, 500 if B2=2, 100 if B2=3, and 50 if B2=4.

CHOOSE takes one argument that must return
integers between 1 and 29, then up to 29
arguments for results to return. You'll
want something like:
=CHOOSE(B1+1, [16 values] )
because you have a starting cell with values from
0 to 15.

Good luck!