vLookup ... help please

S

sarahp

Hi,

I made a mistake last time ....sorry

I have two separates excel workbooks ( not worksheets!!).

Workbook no 1 which has several columns : A ( XP numbers) to O

Workbook no 2 which has two columns : A ( XP numbers) and B ( DOI
numbers)


PS: both workbooks have column A in common ( XP numbers)

I am trying to extract the data from the column B ( DOI numbers ) of
workbook no 2 and insert them into workbook no 1 ONLY when the data
from column A ( XP numbers) match !


Can anyone help me with the formula?
Step by step ...

Also it is possible to automatically repeat the same formula accross
several other workbooks ?:

..... with Workbook no 3 and 4 and 5 ...etc ....( Identical to
woorkbook no 2) : has two columns : A ( XP numbers) and B ( DOI
numbers)

Many thanks

Sarah
 
S

swatsp0p

A formula similar to this should work for you:

=IF(ISNA(VLOOKUP(A2,'C:\M
Documents\[Book2.xls]Sheet1'!$A1:B1000,2,1)),"No
Found",VLOOKUP(A2,'C:\My Documents\[Book2.xls]Sheet1'!$A1:B1000,2,1))

Of course, adjust the path to the other workbook and the lookup rang
as needed.

I added the error trap of ISNA to return "Not Found" if the value i
col. A is not found in the lookup range. Without this, #N/A would b
returned for each value not found.

HT
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top