G
Guest
The requirement is to detect closing of a word document opened by a process.
There is some piece of code which has to be executed after the document is
closed.
Using Process.Start() document is opened, I used process.WaitForExit() to
stop further execution until the document is closed.
But once the document is closed, Process.WaitForExit() throws
“InvalidOperationException-No process is associated to the object†exception.
Even on using process.HasExited property/process.WaitForInputIdle(),same
exception is thrown.
This exception is thrown during Release as well as Debug mode.
Any idea why this exception occurs ?
There is some piece of code which has to be executed after the document is
closed.
Using Process.Start() document is opened, I used process.WaitForExit() to
stop further execution until the document is closed.
But once the document is closed, Process.WaitForExit() throws
“InvalidOperationException-No process is associated to the object†exception.
Even on using process.HasExited property/process.WaitForInputIdle(),same
exception is thrown.
This exception is thrown during Release as well as Debug mode.
Any idea why this exception occurs ?