View Single Post
 
Old 11-02-2013, 02:24 AM
stefaan stefaan is offline Windows 7 64bit Office 2010 64bit
Novice
 
Join Date: Nov 2013
Posts: 2
stefaan is on a distinguished road
Default Automatic update of links in template - closing attached template without saving

Dear all,

I am struggling for days with the following problem. Many threads exist on this topic in this forum and on other websites, but the proposed solutions simply don't seem to work.

In my company we use several word templates (up to 30). In order to prevent that a new user has to manually open each template to add his user details (name, title, unit location, phone number, email, ...) I want to work with one document "User Information" to which the destinated fields in the templates link. So that the correct user information is added automatically when the template is opened. The linking works without a problem. I simply use copy and paste special as a link.

I have chosen for word (instead of excel) given that I find it to be the most user friendly (especially with the forms we use). In addition word is the best accessible for the many computer illiterates at my company.

The problem is that I keep having two annoying issues:

1) when I open the template I want to use (which opens as a normal docx. document) I receive each time the information that the document contains links to other documents and whether I want to update the information. I want this message to stop appearing and that the links simply automatically update.

What I already tried:
- in advanced settings: tick the box for automatically updating links
- using several macros, in particular the ones from this topic: https://www.msofficeforums.com/word/...matically.html

In vain, the same message keeps popping up.

2) when I close the document my pc not only asks me whether I want to save the document itself (which I don't always have to do, but sometimes it is useful) but the template as well (even as I made no changes to it). I understand this is triggered because of the links I use. Again, many information is already available on several forums but none of the suggested macros do the trick. How can I make Word to stop this double saving.

What I already tried:

1) but problem is that their is no active template, given that the template opens as a normal document (as it should).

Sub FileExit()
ActiveTemplate.Saved = True
Application.Quit
End Sub

2) but problem is that VBA gives an error code. VBA does not recognise the attached template.

Sub FileExit()
ActiveDocument.AttachedTemplate.Saved = True
ActiveDocument.AttachedTemplate = ""
End Sub


So, my question is: can anyone get me two macro's that can solve my problem?

Thanks a lot in advance. I spent already too many hours on this.
Reply With Quote