Update dialog box

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

I have a workbook (WB01) whose Workbook_Open() subprocedure opens a second
workbook (WB02). Because WB01 is linked to WB02, the 'This workbook contains
links to other data sources' dialog box is presented to the user. Is there
code that I can put in the Workbook_Open subprocedure to stop this dialog box
from appearing?
 
Sorry for the double posting. In fact, I was surprised either of them
appeared since after hitting 'Post' I was told both times something like
"Sorry. There was a problem with your post. Somebody is being notified."
Thanks for the suggestion, now all I have to do is figure out 'how & where
to do' what you suggested. Am I correct in assuming I need to:
1. create a class module. (I named it "claAppEvents")
2. in claAppEvents 'General' code section have something like "Public
WithEvents XL As Application"
3. create a 'regular' module (I name it "modStartup")
4. in modStartup 'General' code section have something like "Dim App As New
claAppEvents"
5. In my Workbook_Open()procedure for the WB01 include "Set App.XL =
Application"
6. Set WB01 = Workbooks.Open(UpdateLinks:=0)
 
Hi Tim

Use it like this in the Thisworkbook module of WB01

Private Sub Workbook_Open()
Dim WB02 As Workbook
Set WB02 = Workbooks.Open("C:\Data\test1.xls", UpdateLinks:=0)
End Sub
 
Editor will not allow me to enter as "UpdateLinks:=True"
If I enter it without the ":", it bombs out.
 
Ron,

I may not have made myself clear.

I am getting the dialog box when I open the first workbook, WB01, not when
the second, WB02, is opened.

Doesn't this solution address the situation where WB02 was linked to a third
file?

By the way, everytime I post I get the same "there was a problem with your
post......" message. Is this normal?

Thanks again for your help.

Tim Kredlo
 
Doesn't this solution address the situation where WB02 was linked to a third

Yes
I misunderstood you


If you use Excel 2002 or 2003 you have this option in Edit Links
Change it and save the file.
 

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

Back
Top