pinar,
I would recommend you use the VLOOKUP function to achieve the same.
Firstly, list the values and the values they must be mapped to, in your
worksheet. For example, starting from cell D15, enter in range D15:E:17:
10 AA
23 HZ
7 PM
Don't enter any values that do not have a map value. Then, if your numbers
are in column A, starting from 1, in cell B1 enter the formula:
=IF(ISNA(VLOOKUP(A1,$D$15:$E$17,2,FALSE)),0,VLOOKU P(A1,$D$15:$E$17,2,FALSE))
This formula does the following actions:
VLOOKUP(A1,$D$15:$E$17,2,FALSE)
looks up the value in cell A1 (first argument) within the first column of
the range D15:E17 (second argument). If an exact match (4th argument: if
FALSE looks for an exact match) is found, then the corresponding value in
column 2 (3rd argument) of the range is returned by the formula. If no match
is found, then it returns #N/A. This entire function is wrapped in IF() and
ISNA() functions, to determine whether to show 0 or the returned value.
HTH.
"pinar" wrote:
Hi I have a question regarding to excel. I have a column includes numbers. It
is like;
Number:
10
10
7
7
23
55
40
I need specific numbers, lets say that, I only need number 10, 7 and 23 and
then I have to form a new column by using the data in the number column, for
example
If the number is 10 write AA
If the number is 7 write PM
If the number is 23 write HZ
And the other numbers can be deleted or can be 0
So at the end , I have to have something like that
Number Name
10 AA
10 AA
7 PM
7 PM
23 HZ
55 0
40 0
I have around 10 different numbers .Is there any body knows how to do it in
excel. better without writing any macro?
Thanks a lot
|