I’ve encountered an extremely interesting problem today. A user complained about Word 2007 appearing to hang when opening documents and the smallest document take around 30 seconds to open. This should be instant. First thing to try was to narrow the problem down by moving it locally and trying to open it. The problem remained the same, as did it when trying to open the file on a bunch of other clients.
As the Word documents the user was trying to open was in Word 97-2003 format I tried converting it to Word 2007 format but still the problem remained. Renaming the .docx file to .zip (yes, the new docx is just a bunch of xml files that are zipped :) ) and then opening it showed that in the directory “word/rels” there was a settings.xml file that contained references to a template refering to a retired file server. Removing this settings file and zipping the files back up and renaming it to docx and opening it worked like a charm, it opens instantly.
This made me suspect that Word was trying to locate this server but eventually timing out. After installing Network Monitor and running a trace when trying to open the document everything became clear. When opening the file it is actually trying to locate the file server referenced in the file, and it keeps trying until it times our some 30 seconds later. Searching support.microsoft.com gave a few pointers and there are a number of ways to attack this problem but they are all workarounds and half good solutions:
- Edit the problematic files manually by doing what is described above. This is too time consuming if there are many files involved.
- Open all documents, select all and copy and paste the information to a new document, then save it and replace the old one. Also too time consuming if there are many documents.
- There are scripts that go through Word files and replace the bad information, see http://support.microsoft.com/kb/830561.
- I found that KB970270 reference this type of problem and by installing the April 30th hotfix package combined with setting a registry value the problem is worked around. This is still not a solution but instead a work around. See http://support.microsoft.com/kb/970270 for more information. This workaround also applies to the problem with opening documents, verified it myself.