Vairable Fields in a VLookup

  • Thread starter Paul Peterson - Velox Consulting, LLC
  • Start date
P

Paul Peterson - Velox Consulting, LLC

I am using a simple Vlookup below:

=VLOOKUP(A58,[a74]Task_Export_Table!$C$1:$J$200,4,FALSE)

This lookup is in spreadsheet A. It references data from spreadsheet B, a
different spreadsheet located on my hard drive. Because the spreadsheets
will move to other computers/hard drives, I want to allow people to specify
the location of B: I'm using [a74], which includes the drive location
(P:\Testing\etc.) in the vlookup to accomplish this. Unfortunately, if I
change the value in a74, the vlookup doesn't reference the new value but it
appears that it references the original value in A74. Any help would be
appreciated.

Paul C. Peterson.
 
S

Sheeloo

Can you pl. tell me how [a74] works? I have not seen this before...

For your problem try INDIRECT to build the reference to the table.
 
D

Dave Peterson

The function you'd want to use that's built into excel is =indirect(). But that
function returns an error if the sending workbook is closed.

If that's a problem, then Laurent Longre has an addin (morefunc.xll) at:
http://xcell05.free.fr/

That includes =indirect.ext() that may help you.

I am using a simple Vlookup below:

=VLOOKUP(A58,[a74]Task_Export_Table!$C$1:$J$200,4,FALSE)

This lookup is in spreadsheet A. It references data from spreadsheet B, a
different spreadsheet located on my hard drive. Because the spreadsheets
will move to other computers/hard drives, I want to allow people to specify
the location of B: I'm using [a74], which includes the drive location
(P:\Testing\etc.) in the vlookup to accomplish this. Unfortunately, if I
change the value in a74, the vlookup doesn't reference the new value but it
appears that it references the original value in A74. Any help would be
appreciated.

Paul C. Peterson.
 
P

Paul Peterson - Velox Consulting, LLC

Thanks - the A74 is the cell location for the directory structure that
references the external spreadsheet. Depending on who is using the
spreadsheet, the value in that cell will change to a different location.

Sheeloo said:
Can you pl. tell me how [a74] works? I have not seen this before...

For your problem try INDIRECT to build the reference to the table.

Paul Peterson - Velox Consulting said:
I am using a simple Vlookup below:

=VLOOKUP(A58,[a74]Task_Export_Table!$C$1:$J$200,4,FALSE)

This lookup is in spreadsheet A. It references data from spreadsheet B, a
different spreadsheet located on my hard drive. Because the spreadsheets
will move to other computers/hard drives, I want to allow people to specify
the location of B: I'm using [a74], which includes the drive location
(P:\Testing\etc.) in the vlookup to accomplish this. Unfortunately, if I
change the value in a74, the vlookup doesn't reference the new value but it
appears that it references the original value in A74. Any help would be
appreciated.

Paul C. Peterson.
 
P

Paul Peterson - Velox Consulting, LLC

Thanks, Dave. I will try the indirect and the addin.

Dave Peterson said:
The function you'd want to use that's built into excel is =indirect(). But that
function returns an error if the sending workbook is closed.

If that's a problem, then Laurent Longre has an addin (morefunc.xll) at:
http://xcell05.free.fr/

That includes =indirect.ext() that may help you.

I am using a simple Vlookup below:

=VLOOKUP(A58,[a74]Task_Export_Table!$C$1:$J$200,4,FALSE)

This lookup is in spreadsheet A. It references data from spreadsheet B, a
different spreadsheet located on my hard drive. Because the spreadsheets
will move to other computers/hard drives, I want to allow people to specify
the location of B: I'm using [a74], which includes the drive location
(P:\Testing\etc.) in the vlookup to accomplish this. Unfortunately, if I
change the value in a74, the vlookup doesn't reference the new value but it
appears that it references the original value in A74. Any help would be
appreciated.

Paul C. Peterson.
 

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