PDA

View Full Version : automatic external table refresh?



werafa
10-02-2017, 01:12 PM
Hi all,

I've got two external tables (linked excel worksheets - call them a and b)
I want them to automatically refresh on workbook open, or before a user does much else
I don't mind if this is a user triggered event, but need to make it very obvious that this must happen before anything else is done

as background, this database links to these two data input forms, and pulls the data into a consolidated data table for subsequent analysis

How can I do this
(I've searched for a VBA/Macro method, but haven't found the right search terms yet :) )
as an extra twist, I'd like to ensure that the user is forced to select the input data file - (the 'always prompt for new location' option in the linked table manager) - as updates and eofy rollovers may cause the file name to change

many thanks
Werafa

OBP
10-03-2017, 09:09 AM
Have you tried getting a start by recording a macro of the using Link Manager to update the links?
I thought there was a built in function to update links when the workbook was opened, but it is many many years since I have actually Excel to do so.

werafa
10-11-2017, 03:11 AM
the macro needs to be in access - but using the recorder to write the code in excel should, as you say, give a good start.
thanks for the idea, and I'll let you know how I go.