close

Hey there,

I got the following table: see below

Now what I want to do, is to replace the numbers with words.

In words this would look something like this

FOR ROW Q:

If Value'Q' = 1 replace by A
If Value'Q' = 2 replace by B

FOR ROW R:

If Value'Q' = 1 and Value 'R' = 1 replace by aa
If Value'Q' = 1 and Value 'R' = 2 repalce by aa'
If Value'Q' = 2 and Value 'R' = 1 replace by bb

etc ...

I hope this explains it.

Cheers and thx a lot.

Philipp -------------------------------------------------------------------
|Filename: TABLE1.JPG |
|Download: www.excelforum.com/attachment.php?postid=4599 |
-------------------------------------------------------------------

--
Emsmaps
------------------------------------------------------------------------
Emsmaps's Profile: www.excelforum.com/member.php...oamp;userid=33265
View this thread: www.excelforum.com/showthread...hreadid=530880
I guess the two difficulties are that 1) Excel doesn't replace other
cell values unless you use VB code, and 2) in a 2 part test, if
Value'Q' were replaced then value R would fail the test because value Q
was no longer a 1 or 2, therefore the test is failed, therefore the Q
value should not have been changed (or something like that)

So, instead of 'changing' the values, I would use a second sheet and in
cell A1 put:

=IF(Sheet1!A1=quot;quot;,quot;quot;,Sheet1!A1)

and formula-drag that across and down to cover all required cells.

This would give me an active copy. (ie, if you change Sheet1 it will be
reflected here)

Then, for the required Q row, in cell Q1 use

=IF(Sheet1!Q1=quot;quot;,quot;quot;,if(Sheet1!Q1=1,quot;Aquot;,Sheet1!Q1))

and formula drag that across for the number of cells required to be
changed,

and for row R, in cell R1 put=IF(Sheet1!R1=quot;quot;,quot;quot;,IF(AND(Sheet1!Q1=1,Sheet1!R1=1 ),quot;aaquot;,IF(AND(Sheet1!Q1=1,Sheet1!R1=2),quot;aa'quot;,IF(AN D(Sheet1!Q1=2,Sheet1!R1=1),quot;bbquot;,Sheet1!R1))))

and formula drag that down to cover all required cells.

This should provide the look you require.

-Note, when you copy and paste these formula, watch for inserted spaces
and remove them. -
--
Emsmaps Wrote:
gt; Hey there,
gt;
gt; I got the following table: see below
gt;
gt; Now what I want to do, is to replace the numbers with words.
gt;
gt; In words this would look something like this
gt;
gt; FOR ROW Q:
gt;
gt; If Value'Q' = 1 replace by A
gt; If Value'Q' = 2 replace by B
gt;
gt; FOR ROW R:
gt;
gt; If Value'Q' = 1 and Value 'R' = 1 replace by aa
gt; If Value'Q' = 1 and Value 'R' = 2 repalce by aa'
gt; If Value'Q' = 2 and Value 'R' = 1 replace by bb
gt;
gt; etc ...
gt;
gt; I hope this explains it.
gt;
gt; Cheers and thx a lot.
gt;
gt; Philipp--
Bryan Hessey
------------------------------------------------------------------------
Bryan Hessey's Profile: www.excelforum.com/member.php...oamp;userid=21059
View this thread: www.excelforum.com/showthread...hreadid=530880

arrow
arrow
    全站熱搜
    創作者介紹
    創作者 software 的頭像
    software

    software

    software 發表在 痞客邦 留言(0) 人氣()