views:

77

answers:

1

In my application i am using word automation to get the text content from the file. It is working fine no issues. But at the instant when word automation is processing, if i open the word file, it is throwing a dialog with message (any file)

"This file is in use by another application or user. (C:\User\xyz\AppData...\Normal.dotm)".

When I am closing the dialog, it is asking for save the file "normal.dotm"...template file.

This happens only in MSWord 2007 not in MSWord 2003. can any one tell the solution please.

+1  A: 

This probably happens because one Word instance has locked Normal.dotm and your instance modifies it and tries to save it.

You can try to set the Saved property of your template to True. Try this: Application.NormalTemplate.Saved := True. Word will now think that changes to Normal.dotm are saved and should not try to save again.

The_Fox