ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Discussion (Misc queries) (https://www.excelbanter.com/excel-discussion-misc-queries/)
-   -   Array? (https://www.excelbanter.com/excel-discussion-misc-queries/16432-array.html)

Mindie

Array?
 
I am trying to find out how I can do this. I have 3 sheets in my workbook.
On sheet one I am trying to compare one cell to other cells in sheet 2 and
the answers are in the next row under these cells. I want to display these
answers on another cell in sheet 3. For example: Sheet1!E5=C1 THEN DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the answer to
E5 and so on.

Bob Phillips

=INDEX(D:D,MATCH(Sheet1!E5,C:C,0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I am trying to find out how I can do this. I have 3 sheets in my

workbook.
On sheet one I am trying to compare one cell to other cells in sheet 2 and
the answers are in the next row under these cells. I want to display

these
answers on another cell in sheet 3. For example: Sheet1!E5=C1 THEN

DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the answer

to
E5 and so on.




Mindie

I have tried doing this but I keep getting #N/A?

"Bob Phillips" wrote:

=INDEX(D:D,MATCH(Sheet1!E5,C:C,0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I am trying to find out how I can do this. I have 3 sheets in my

workbook.
On sheet one I am trying to compare one cell to other cells in sheet 2 and
the answers are in the next row under these cells. I want to display

these
answers on another cell in sheet 3. For example: Sheet1!E5=C1 THEN

DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the answer

to
E5 and so on.





Bob Phillips

That suggests I may have got the data wrong way around.

The formula is saying, match the value in Sheet1 cell E5 against column C on
this worksheet, and when found, get the corresponding value from column D.
Is this how it should be?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I have tried doing this but I keep getting #N/A?

"Bob Phillips" wrote:

=INDEX(D:D,MATCH(Sheet1!E5,C:C,0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I am trying to find out how I can do this. I have 3 sheets in my

workbook.
On sheet one I am trying to compare one cell to other cells in sheet 2

and
the answers are in the next row under these cells. I want to display

these
answers on another cell in sheet 3. For example: Sheet1!E5=C1 THEN

DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the

answer
to
E5 and so on.







Mindie

No you were correct in the way that I told you, but the issue I am having
right now is if it doesn't find a match, I get #n/a, and I would prefer to
show blanks. How do I do that?

"Bob Phillips" wrote:

That suggests I may have got the data wrong way around.

The formula is saying, match the value in Sheet1 cell E5 against column C on
this worksheet, and when found, get the corresponding value from column D.
Is this how it should be?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I have tried doing this but I keep getting #N/A?

"Bob Phillips" wrote:

=INDEX(D:D,MATCH(Sheet1!E5,C:C,0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I am trying to find out how I can do this. I have 3 sheets in my
workbook.
On sheet one I am trying to compare one cell to other cells in sheet 2

and
the answers are in the next row under these cells. I want to display
these
answers on another cell in sheet 3. For example: Sheet1!E5=C1 THEN
DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the

answer
to
E5 and so on.







Bob Phillips

Okay, that's easy enough

=IF(ISNA(MATCH(Sheet1!E5,C:C,0)),"",INDEX(D:D,MATC H(Sheet1!E5,C:C,0)))


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
No you were correct in the way that I told you, but the issue I am having
right now is if it doesn't find a match, I get #n/a, and I would prefer to
show blanks. How do I do that?

"Bob Phillips" wrote:

That suggests I may have got the data wrong way around.

The formula is saying, match the value in Sheet1 cell E5 against column

C on
this worksheet, and when found, get the corresponding value from column

D.
Is this how it should be?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I have tried doing this but I keep getting #N/A?

"Bob Phillips" wrote:

=INDEX(D:D,MATCH(Sheet1!E5,C:C,0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I am trying to find out how I can do this. I have 3 sheets in my
workbook.
On sheet one I am trying to compare one cell to other cells in

sheet 2
and
the answers are in the next row under these cells. I want to

display
these
answers on another cell in sheet 3. For example: Sheet1!E5=C1

THEN
DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the

answer
to
E5 and so on.









Mindie

Thanks, that worked perfectly!

"Bob Phillips" wrote:

Okay, that's easy enough

=IF(ISNA(MATCH(Sheet1!E5,C:C,0)),"",INDEX(D:D,MATC H(Sheet1!E5,C:C,0)))


--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
No you were correct in the way that I told you, but the issue I am having
right now is if it doesn't find a match, I get #n/a, and I would prefer to
show blanks. How do I do that?

"Bob Phillips" wrote:

That suggests I may have got the data wrong way around.

The formula is saying, match the value in Sheet1 cell E5 against column

C on
this worksheet, and when found, get the corresponding value from column

D.
Is this how it should be?

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I have tried doing this but I keep getting #N/A?

"Bob Phillips" wrote:

=INDEX(D:D,MATCH(Sheet1!E5,C:C,0))

--

HTH

RP
(remove nothere from the email address if mailing direct)


"Mindie" wrote in message
...
I am trying to find out how I can do this. I have 3 sheets in my
workbook.
On sheet one I am trying to compare one cell to other cells in

sheet 2
and
the answers are in the next row under these cells. I want to

display
these
answers on another cell in sheet 3. For example: Sheet1!E5=C1

THEN
DISPLAY
D1 as the answer to E5, or If Sheet1!E5=C2, then display D2 as the
answer
to
E5 and so on.











All times are GMT +1. The time now is 02:26 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com