Vlookup

  • Thread starter Thread starter aj
  • Start date Start date
A

aj

Hi- I am using vlookup where the lookup table is in another file, I
have the file name in a cell of the sheet, please let me know how to
refer to the file name and range name in the vlookup function by using
the cell address that contains the file name.
 
One way:

=VLOOKUP(A1,INDIRECT("'[" & A2 & "]Sheet1'!A:B"),2,FALSE)

However, for INDIRECT, the file must be open or you'll get a #Ref! error.

To work with closed workbooks, you could use the INDIRECT.EXT function
in Laurent Longre's MOREFUNC.xll add-in:

http://xcell05.free.fr/
 
Back
Top