Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default Returning a Cell Value

I have 2 workbooks, Book 1 and Book 2.

Book 1 has a number in Cell A1. I want to find Book 1 Cell A1 value in a
Cell in Book 2 from a Column (lets say B) of numbers. Once I find that value
I want to return the value of a different cell in that row.

Can this be done?
--
Jeff
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Returning a Cell Value

One way is to use INDEX/MATCH which allows you to match on any col, then
return any other col to the left/right of the match col

In Book1, in Sheet1,

Assume in A1 down contains the numbers to be matched

you could place this in B1:
=INDEX('[Book2.xls]Sheet1'!$C:$C,MATCH(A1,'[Book2.xls]Sheet1'!$B:$B,0))
Copy B1 down as far as required

The MATCH part of it:
MATCH(A1,'[Book2.xls]Sheet1'!$B:$B,0)
will match A1 with what's within col B in Book2.xls's Sheet1

When the match is found, this INDEX part:
INDEX('[Book2.xls]Sheet1'!$C:$C
then retrieves the corresponding value from col C in Book2.xls's Sheet1

If there's no match found, you'd get an ugly #N/A. If you want to return
clean looking blanks: "" instead for unmatched cases, use this in B1:
=IF(ISNA(MATCH(A1,'[Book2.xls]Sheet1'!$B:$B,0)),"",INDEX('[Book2.xls]Sheet1'!$C:$C,MATCH(A1,'[Book2.xls]Sheet1'!$B:$B,0)))

Hope the above clarifies the index/match workings. Adapt to suit.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"bhbjk1" wrote in message
...
I have 2 workbooks, Book 1 and Book 2.

Book 1 has a number in Cell A1. I want to find Book 1 Cell A1 value in a
Cell in Book 2 from a Column (lets say B) of numbers. Once I find that
value
I want to return the value of a different cell in that row.

Can this be done?
--
Jeff



  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Returning a Cell Value

Clarification. The preceding formulas assumes that
you have both Book1.xls & Book2.xls open simultaneously
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---


  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 8
Default Returning a Cell Value

Worked Great Thanks
--
Jeff


"Max" wrote:

Clarification. The preceding formulas assumes that
you have both Book1.xls & Book2.xls open simultaneously
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---



  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
Max Max is offline
external usenet poster
 
Posts: 9,221
Default Returning a Cell Value

welcome, Jeff.
--
Max
Singapore
http://savefile.com/projects/236895
xdemechanik
---
"bhbjk1" wrote in message
...
Worked Great Thanks
--
Jeff



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
Returning Cell Contents of One Cell Based On Another Cell DallasLDY Excel Worksheet Functions 5 January 31st 07 11:00 PM
vlookup is returning a value one cell above the correct cell. dbaker4 Excel Worksheet Functions 4 April 20th 06 08:21 PM
returning a cell name brandon Excel Worksheet Functions 3 April 18th 06 10:03 PM
Returning Cell Value if someone deletes the contents of a cell mmc308 Excel Worksheet Functions 4 March 31st 06 06:41 PM
returning a text cell based on a number cell Josh7777777 Excel Worksheet Functions 2 November 2nd 04 07:42 PM


All times are GMT +1. The time now is 05:57 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"