ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   Refresh External Data code (https://www.excelbanter.com/excel-programming/432709-refresh-external-data-code.html)

Tony7659

Refresh External Data code
 
Every time I open a file that brings external data, it gives me a pop-up
message asking if I want to enable or disable refresh. I need have some code
that once the file opens, refreshes the external data (enabled) and keep
going without stopping. Any ideas? Thanks. Tony.

smartin

Refresh External Data code
 
Tony7659 wrote:
Every time I open a file that brings external data, it gives me a pop-up
message asking if I want to enable or disable refresh. I need have some code
that once the file opens, refreshes the external data (enabled) and keep
going without stopping. Any ideas? Thanks. Tony.


I would say...

Try using the Link manager to tell the workbook to always refresh linked
data without prompting. In Excel 2003 this is done in Edit | Links... |
Startup Prompt...

This property can also be set in code:

ActiveWorkbook.UpdateLinks = xlUpdateLinksAlways

But then again...

This doesn't always work for me. In some workbooks where I have set "no
alert, update links", I get prompted anyway. It's as though sometimes
the setting is completely ignored. I always have macro security on "low"
FWIW.


All times are GMT +1. The time now is 05:30 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com