different numbers to return different letters

KenWright64

New Member
Joined
Nov 16, 2005
Messages
8
I want to return a choice of 4 letters(w,x,y,z) in one cell depending upon the result of a number in another cell. For example - if cell A2 was between 1 & 5 I want to return the letter w in cell C2, If cell A2 was between 6 & 10 I
want to return letter x in C2, I thank you as all i get is true/false with If statements
 

Excel Facts

What does custom number format of ;;; mean?
Three semi-colons will hide the value in the cell. Although most people use white font instead.
Welcome to MrExcel Board!

How about this?:

=IF(AND(A2>=1,A2<=20),CHAR(QUOTIENT(A2-1,5)+119),"Not in range")

Hope that helps!
 
Upvote 0
KenWright64 said:
I want to return a choice of 4 letters(w,x,y,z) in one cell depending upon the result of a number in another cell. For example - if cell A2 was between 1 & 5 I want to return the letter w in cell C2, If cell A2 was between 6 & 10 I
want to return letter x in C2, I thank you as all i get is true/false with If statements
Hi KenWright64:

Welcome to MrExcel Board!

You mean something like ...

=IF(AND(A2>=6,A2<=10),"x",IF(AND(A2>=1,A2<=5),"w"))
 
Upvote 0
KenWright64

Not sure where y and z come into it but this structure might also be some use:
=LOOKUP(A2,{1,6,11,16},{"w","x","y","z"})
 
Upvote 0

Forum statistics

Threads
1,216,487
Messages
6,130,946
Members
449,608
Latest member
jacobmudombe

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top