Instantiating Word prevents users from closing Word interactively

M

Mike Leftwich

Our app instantiates Word to use the spell checker. The problem is that
when our app is running in some environments, and the user separately opens
a document and then tries to close it, they get "The file is in use by
another application or user. (...\normal.dot)". The environments in which
this happens seem to be where one or more custom document templates are
being used (law firms). I do see that when I instantiate Word and then add
a document to the documents collection that normal.dot is held open. I'm
assuming that when the user is trying to quit their document, Word or the
custom document template is trying to save normal.dot. If that's the
problem, is there any way for me to add a document without holding a
template open? I tried making the document that I added a "new template"
but it still seems to hold normal.dot open. Or if there's a better
approach, let me know!

Thanks very much for the help.

Mike
 
C

Cindy M -WordMVP-

Hi Mike,

I'm afraid there's no way to "unlink" an instance of Word from the Normal.dot
template. This is a global template, that's also acting as an Addin and
default storage place for user customizations. There's really no good way
around this, for what you're trying to do (in essence, "hijack" Word for your
own use in another application). Best bet would be to "share" the instance of
Word with the user.
Our app instantiates Word to use the spell checker. The problem is that
when our app is running in some environments, and the user separately opens
a document and then tries to close it, they get "The file is in use by
another application or user. (...\normal.dot)". The environments in which
this happens seem to be where one or more custom document templates are
being used (law firms). I do see that when I instantiate Word and then add
a document to the documents collection that normal.dot is held open. I'm
assuming that when the user is trying to quit their document, Word or the
custom document template is trying to save normal.dot. If that's the
problem, is there any way for me to add a document without holding a
template open? I tried making the document that I added a "new template"
but it still seems to hold normal.dot open. Or if there's a better
approach, let me know!

Cindy Meister
INTER-Solutions, Switzerland
http://homepage.swissonline.ch/cindymeister (last update Jun 8 2004)
http://www.word.mvps.org

This reply is posted in the Newsgroup; please post any follow question or
reply in the newsgroup and not by e-mail :)
 

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

Top