Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Slow opening of Micorsoft Word Documents

Status
Not open for further replies.

Crookshanks

Technical User
May 18, 2004
296
NL
[This post was also posted in Microsoft Office]

Hello there,

I am trying to solve a problem with some Microsoft Word documents which are the result of the standard templates of the company . The problem in short is that whenever the documents are opened outside our environment it takes unacceptable long to do so. I was wondering whether somebody here could give me some hints for starting to search in the right direction in order to solve the problem. Here some additional information:

• The company has also an establishment in England (I am the Netherlands), when people over there try to open the document it takes about 5-10 minutes. No error messages is displayed, it just takes a long while.
• When I unplug my network cable and open the document on my machines it opens immediately and displays correctly. As there is no possibility to get external information, the machine does not try to retrieve it.
• With a network connection available (but not on the correct domain) the opening of the document takes about 30 seconds (significantly faster than in England). The systems shows the hourglass and after a while the documents opens correctly. When I close Word and reopen the document it appears immediately. Could be something in the cache. After logging off it takes again 30 seconds to open the document for the first time.
• After logging on in the right domain the document also opens immediately.

In each of the above cases the document opens correctly (with logo, reviews, tables etc.), there is nothing missing. From this we may conclude that all the necessary information is within the document but that the system nevertheless tries to retrieve external information through the network.

Questions:
1) Does anybody recognize this problem?
2) How can I check what the system looks for? What should I to do to make the requests for information visible?
3) I have absolutely no clue what information the machine is searching for. It just shows the famous hourglass for a while. Any ideas?
4) Is there a way to prevent the system looking for external information?

Any help much appreciated. Kind regards,
 
You may want to repost this question in the Microsoft Office Forum.

forum68

I hope this helps.

Ron Repp

If gray hair is a sign of wisdom, then I'm a genius.
 
Word and networked resources just don't tend to work very well together.

If the documents have been created from a template on a server in the Netherlands and then copied to a server in England, they retain an attachment to the Dutch server - and when opened in England, Word tries to open the attached Template in The Netherlands (going via Saturn, I think). There may be no need to open the Template (as you say, all the bits are in the document) but Word doesn't know that until it's done it. One way to avoid it is to have a copy of the Template in the same (local) Folder as the Document - another is to attach a different template (normal.dot perhaps) after creating the document if the original template is no longer required.

Enjoy,
Tony

------------------------------------------------------------------------------------
We want to help you; help us to do it by reading this: Before you ask a question.

Professional Office Developers Association
 
Thanks for your answer. It is very useful as it confirms my thoughts. I will try a new post with this information as a fact to look for possible more solutions / workarounds. Thanks again!
 
I had the same problem, Tony is right, Word is looking for the origianl template that was used to create the document.

In my case, since the documents were being created from a VBA form, I simply attach a null template before saving.

ActiveDocument.AttachedTemplate =
 
Mintjulup, that is another way trying to tackle the problem. Thanks for your contribution. 'My' Documents are not created by a form but only with a ordinary .dot file.

Question: Would it be a good idea to put the statement
Code:
ActiveDocument.AttachedTemplate = ""
in de the close or save event of the .dot file. Is there a chance to lose valuable information in this way?


 
Question: I do not normally do things like change templates. I just tried to do
Code:
ActiveDocument.AttachedTemplate = ""

I have now tried 23 different documents (from 23 different templates) and ALL of them return:

Run-time error 5957:
Could not change document template.

Oh....never mind. There is something wrong. ANY change in attached template is failing. I thought it may have some quirk with "", but a valid path to a template also fails.

Word refuses to let me change the attached template at all.

Hmmmmmmm.

Gerry
My paintings and sculpture
 
I don't think it would work in the close event of a .dot.

At the instant in time that it would fire, the template would be the active document, so you would be attempting to attach a null template to a template. I suspect that would confuse things tremendously.

 
All of our templates now have an AutoNew macro with the lines:
Code:
With ActiveDocument
	.UpdateStylesOnOpen = False
	.AttachedTemplate = ""
End With
Alternatively, if the template has its own startup code, we add those lines at the end.

This is to prevent the problem that Crookshanks has - by default, documents are 'attached' to the template they were created from and when that's not available, Word can take a long time to search for it. I'm guessing that the length of time is down to network configuration, i.e. how long the network searches for a resource before it returns a 'time out' error.

You can fix existing documents by opening them, going to the 'Tools' menu, choosing 'Templates and Add-Ins', deleting whatever's in the 'Document template' box, clicking 'OK' and saving the document. That can be quite time-consuming if you have many documents though.

This was a huge problem for us a few years ago when we re-configured our network, re-naming servers and so on. All of our Word documents suddenly took ages to open becasuse they were looking for templates that weren't there any more.

Regards

Nelviticus
 
Thanks Nelviticus. I will add this to new templates. I will look further for a (fast) solution for the documents already made.
 
If you can manage easily (which may depend on how your documents are organised) having a copy of the template (with the same name but not, obviously, path) in the same folder as the document will stop Word looking at the actual path of the atteched template. That copy of the template could then have code to change the attached template so that it would, in effect, be used once per document.

Enjoy,
Tony

------------------------------------------------------------------------------------
We want to help you; help us to do it by reading this: Before you ask a question.

Professional Office Developers Association
 
Darn. Before I try and do a reinstall (Repair did not work) does anyone have any thought regarding Word failing to accept an AttachedTemplate change?

Full scan and no detected virus etc. etc etc.

It refuses to do anything with ActiveDocument.AttachedTemplate = anything

Correct path and file names known.

Gerry
My paintings and sculpture
 
It refuses to do anything with ActiveDocument.AttachedTemplate = anything
Even with a brand new document created from a template but not yet saved ?

Hope This Helps, PH.
Want to get great answers to your Tek-Tips questions? Have a look at FAQ219-2884 or FAQ181-2886
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top