Access denied when instantiating word 2000

J

Jack Jiao

Hi,

I am using MS Word inside C# application. The application is using
impersonation as Administrator. The application works fine for a few days
then suddenly I started to get "access is denied" message everytime I
instantiate instantiate MS word like "oWordApp = new
Word.ApplicationClass();" Not just this application, any application uses
word automation now don't work any more.

There's nothing I can do to make the error go away. But if I remove and
reinstall Office 2000 then the application starts to work again, for a few
more days before it starts to generate this error again. I see no instance
of winword in task manager hanging around.

I have no clue what causes this problem and no idea why it goes away when I
reinstall office 2000.

Thank you for your suggestions.
 
E

Elton Wang

Hi Jack,

Do you use
System.Runtime.InteropServices.Marshal.ReleaseComObject
(oWordApp) to release the object after using it?

Anyway, it's not a good idea to use automation on server.

HTH

Elton Wang
(e-mail address removed)
 

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

Members online

Forum statistics

Threads
473,770
Messages
2,569,584
Members
45,075
Latest member
MakersCBDBloodSupport

Latest Threads

Top