ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   Lookup? (https://www.excelbanter.com/excel-worksheet-functions/128657-lookup.html)

Shelly

Lookup?
 
I have a workbook with 2 sheets. I want to compare the value in Sheet2!A1
to a range of cells in Sheet 1 (Sheet1!a1:a300). If the value in Sheet2:A1
finds a matching in the range of Sheet1!a1:a300), then the value of Sheet1!b1
should be copied to Sheet2!b1.

I'm sure there's a Lookup in there somewhere, but don't know where to start.

THANKS!

Bob Phillips

Lookup?
 
in Sheet2!B1

=IF(ISNA(MATCH(A1,Sheet1!A1:A300,0)),"",Sheet1!B1)

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Shelly" wrote in message
...
I have a workbook with 2 sheets. I want to compare the value in Sheet2!A1
to a range of cells in Sheet 1 (Sheet1!a1:a300). If the value in
Sheet2:A1
finds a matching in the range of Sheet1!a1:a300), then the value of
Sheet1!b1
should be copied to Sheet2!b1.

I'm sure there's a Lookup in there somewhere, but don't know where to
start.

THANKS!




Shelly

Lookup?
 
This is close, but the order of the two lists are different.

In Sheet2, there is a list for product names in alphabetical order from
a6:a300.
In Sheet1, this list of products are based on category from a6:a300

So, I need to copy the value of the cell directly to the right of the list
in Sheet 1. For example:

in Sheet 2, cell A6 is the product "Cars", the cell B6 is blank
in Sheet 1, somewhere in the range of A6:a300 is the product "Cars", and in
the cell diretly to the right of that cell is either an X or a number.
I need to copy that value (the X or the number) to B6.

Thanks!!

"Bob Phillips" wrote:

in Sheet2!B1

=IF(ISNA(MATCH(A1,Sheet1!A1:A300,0)),"",Sheet1!B1)

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Shelly" wrote in message
...
I have a workbook with 2 sheets. I want to compare the value in Sheet2!A1
to a range of cells in Sheet 1 (Sheet1!a1:a300). If the value in
Sheet2:A1
finds a matching in the range of Sheet1!a1:a300), then the value of
Sheet1!b1
should be copied to Sheet2!b1.

I'm sure there's a Lookup in there somewhere, but don't know where to
start.

THANKS!





Bob Phillips

Lookup?
 
I think this is what you want then

=IF(ISNA(MATCH(A1,Sheet1!$A$1:$A$300,0)),"",INDEX( Sheet1!$B$1:$B$300,MATCH(A1,Sheet1!$A$1:$A$300,0)) )


--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"Shelly" wrote in message
...
This is close, but the order of the two lists are different.

In Sheet2, there is a list for product names in alphabetical order from
a6:a300.
In Sheet1, this list of products are based on category from a6:a300

So, I need to copy the value of the cell directly to the right of the list
in Sheet 1. For example:

in Sheet 2, cell A6 is the product "Cars", the cell B6 is blank
in Sheet 1, somewhere in the range of A6:a300 is the product "Cars", and
in
the cell diretly to the right of that cell is either an X or a number.
I need to copy that value (the X or the number) to B6.

Thanks!!

"Bob Phillips" wrote:

in Sheet2!B1

=IF(ISNA(MATCH(A1,Sheet1!A1:A300,0)),"",Sheet1!B1)

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my
addy)



"Shelly" wrote in message
...
I have a workbook with 2 sheets. I want to compare the value in
Sheet2!A1
to a range of cells in Sheet 1 (Sheet1!a1:a300). If the value in
Sheet2:A1
finds a matching in the range of Sheet1!a1:a300), then the value of
Sheet1!b1
should be copied to Sheet2!b1.

I'm sure there's a Lookup in there somewhere, but don't know where to
start.

THANKS!








All times are GMT +1. The time now is 12:55 PM.

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