Why does COM Word automation from a console application start as a scheduled task on my development machine, but hang on another?

I have a console application that uses COM Automation to manage .DOC and .DOCX files in Word 2010. This works in a scheduled task for an unregistered user account on two development machines (with Windows Server 2003 32-bit), but not on a different machine (running Windows Server 2003 64-bit). It runs on that computer if it is run from the command line by the same user account when logged in (so I don't think this is a 32/64 bit issue).

The code hangs in the place where it tried to open the document not when creating the Word application.

I signed up as a user account and opened the file manually (so I don't think it opens all the dialog boxes).

I thought it might have something to do with autosave, and while looking at the checking options, I noticed that the "automatically use corrections from spellcheck" checkbox was grayed out.

I used the process monitor and couldn't find file access failures for files that are on the dev machine but not the other (Word seems to be looking for Normal.dot in several places, but this file is not on dev).

I know that Word Server Automation is not recommended or supported by Microsoft and may be outside the license terms.

I am using automation as I need to manipulate files for older versions of Word.

This may be related to my other problem with automation from unregistered accounts: Why does COM automation from a console application work on my development machine but not on the other? However, this case is different in that opening the file hangs and does not crash the application.

What else should I try?

+3


source to share





All Articles