Link to home
Start Free TrialLog in
Avatar of FLUXWIRE
FLUXWIRE

asked on

Help. Asp.net and word

Hi All!

I have an asp.net application where i run a word application on the server.

appWord = new Word.Application();
appWord.Visible = false;
try
{
     appWord.Documents.Open(ref strFile, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing, ref oMissing);
     Word.Document docWord = appWord.ActiveDocument;

after some process i quit the word application using

appWord.Quit(ref oMissing, ref oMissing, ref oMissing);

BUT. the WINWORD.EXE remains running.

HELP!
Avatar of zero303
zero303

Are you sure the server isn't running outlook or something? Outlook uses word to write email by default...
Avatar of FLUXWIRE

ASKER

FYI!

if for any reason, the application quits, the winword.exe remains executing and only if i kill the process using the task manager i can use the app again.

How can i know if there is an winword.exe instance running and kill it before my application starts a new one?

thx in advance!
k.
the first one (from forum.aspfree.com) didnt work. there is no dispose to doc.

i will try the second. but let me ask.

if i am using a asp.net application, several users could be running one winword application. right? How can i know what is the correct instance to kill?

thx

ASKER CERTIFIED SOLUTION
Avatar of spongie
spongie
Flag of Philippines image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
spongie!

appWord.ActiveDocument.Close(ref oMissing, ref oMissing, ref oMissing);
appWord.Quit();
appWord=null;

thats works! thx