Skip to main content

[archive] Killing old copies of MS Word

  • May 20, 2009
  • 1 reply
  • 0 views

[Migrated content. Thread originally posted on 19 May 2009]

We use ACUCOBOL to build, using mailmerge, and display MS Word documents. Sometimes the user kills acuthin or it dies and leaves the MS Word application running. As this performs a mailmerge it can end up having various files open and when the user re-starts the application the new copy of Word cannot access these files. I need a way of killing the old copy of Word. I have saved the handle of the application in a file but when I detect this file and extract the handle and try to either QUIT() or destroy the MS Word application, acuthin dies with the message:

ACUCOBOL-GT Thin Client has encountered a problem and needs to close. We are sorry for the inconvenience.

Does anybody have any suggestions please?

1 reply

[Migrated content. Thread originally posted on 19 May 2009]

We use ACUCOBOL to build, using mailmerge, and display MS Word documents. Sometimes the user kills acuthin or it dies and leaves the MS Word application running. As this performs a mailmerge it can end up having various files open and when the user re-starts the application the new copy of Word cannot access these files. I need a way of killing the old copy of Word. I have saved the handle of the application in a file but when I detect this file and extract the handle and try to either QUIT() or destroy the MS Word application, acuthin dies with the message:

ACUCOBOL-GT Thin Client has encountered a problem and needs to close. We are sorry for the inconvenience.

Does anybody have any suggestions please?
The handle you have saved is unique for the particular instance of ACUCOBOL-GT and cannot be reused by other instances of the runtime.
Unfortunately, I believe your only method of shutting down pending instances of MS Word is either by the task manager (which involves user interaction) or restarting the machine.