Using cell value as filename to return a value from a closed workbook

AndrewMB

Board Regular
Joined
Feb 3, 2008
Messages
75
Good evening everyone,

I have a list of filenames in column A. The list is long. In another column I want a generic formula I can drag down that will return a value from the same cell in each of those files.

Currently, they are written manually like this;

=('P:\FORD BUSINESS UNIT\Quality\FORD SPC\SPC Analysis\eSPC\[SPC5260-02 cav2 Small Spig Seal Dia Lowest 201217.xlsx]Master'!$Y$3)

The filename in column A in this example would be; SPC5260-02 cav2 Small Spig Seal Dia Lowest 201217.


Is there a way of referencing the filename from column A? Ideally from the sheet but vba if needs be.
 

Excel Facts

Convert text numbers to real numbers
Select a column containing text numbers. Press Alt+D E F to quickly convert text to numbers. Faster than "Convert to Number"
This work?
Code:
=INDIRECT("('P:\FORD BUSINESS UNIT\Quality\FORD SPC\SPC Analysis\eSPC\["&$A1&".xlsx]Master'!$Y$3)")
 
Upvote 0
Thank you.

I know from reading, that INDIRECT will only work when the workbook is open, however, saying that, I can't even get that to pull a value in when it's open.
 
Upvote 0
What version of Excel do you use?

What is the value of A1?
 
Upvote 0
If you remove the file path from the formula, does it work?

Also, how is it not working? Error? No result? Something else?
 
Upvote 0
How about
=INDIRECT("'P:\FORD BUSINESS UNIT\Quality\FORD SPC\SPC Analysis\eSPC\["&$A1&".xlsx]Master'!$Y$3")
 
Upvote 0

Forum statistics

Threads
1,224,828
Messages
6,181,204
Members
453,022
Latest member
RobertV1609

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top