Open files in VBA without updating external links

svjensen

Board Regular
Joined
Jun 10, 2009
Messages
118
Using VBA I need to open a number of files, do what ever I need to do (i.e. update a formula) and close it again.

This all works well, but I would like to be able to decide if the workbook I am opening should update external links or not. This should be done without being shown the dialogue box.

The files are opened using:
Code:
Workbooks.Open Filename:=arrFiles(i)

I expect that I can add an other argument but am uncertain how.

/Soren
 

Excel Facts

Save Often
If you start asking yourself if now is a good time to save your Excel workbook, the answer is Yes
That seems to do the trick, thanks.
I assume that if I replace the '0' with '1' then it will automatically update links without prompting?

/Soren
 
Upvote 0
From the Help

<table cellpadding="4" cellspacing="4" cols="2"><tbody><tr valign="top"> <th width="20%">Value</th> <th width="80%">Meaning</th></tr> <tr valign="top"> <td class="TT" width="20%">0</td> <td class="TT" width="80%">Doesn't update any references</td></tr> <tr valign="top"> <td class="TT" width="20%">1</td> <td class="TT" width="80%">Updates external references but not remote references</td></tr> <tr valign="top"> <td class="TT" width="20%">2</td> <td class="TT" width="80%">Updates remote references but not external references</td></tr> <tr valign="top"> <td class="TT" width="20%">3</td> <td class="TT" width="80%">Updates both remote and external references</td></tr></tbody></table>
 
Upvote 0
Thanks.
I looked for the difference between 'remote' and 'external' references in Excel help and on the Internet, but did not find an answer.
Anyone who can help with that?
 
Upvote 0
A remote reference is a reference to another application (eg Word). An external reference is a reference to another Excel workbook.
 
Upvote 0

Forum statistics

Threads
1,215,002
Messages
6,122,652
Members
449,092
Latest member
peppernaut

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