TransferSpreadsheet

N

Nick

I have a macro TransferSpreadsheet that imports my data.
What I would like to do is have the details for the File
Name to come from a field in a table.
The table is called tbDefaults and the field is
File_Location. This is because I get data from different
servers, eg G:\Crushing Shedules\Backlog\BACKLOG.xls. So
to select a different file location I can look it up and
then refresh.

I hope this is do-able.
Regards
Nick
 
K

Ken Snell [MVP]

For the File Name argument, use an expression involving the DLookup
function:

=DLookup("FileNameField", "TableName")

The above can be modified to include a WHERE clause's expression for
filtering the result.
 

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