S
Stephen Barrett
Hi all,
I am currently using VB to interface to WORD through COM. Basically, I am
creating a txt based mailmerge file, opening a specific mailmerge document,
merging it with created file, and printing it to a pseudo printer that
converts the document to a PDF file.
I have no control over the authoring of the mail merge document. This
process runs on a server non-interactively. I FULLY understand that Word is
not meant to run as a service process due to all the documented reasons and
MGMT understands it as well. However, we are where we are.
There are certain things that users can do that causes Word to absolutely go
crazy and end up eating tons of CPU. In fact, one user managed to created a
document that had very complicated table nesting within IFF conditions that
actually inadvertently generated unlimited number of print pages. They
kicked this off numerous times and brought the server to its knees.
I would like to be able to kill the Word process directly after a set time
to help protect the server. I can't do this through COM because it is
basically waiting on the merge/print to finish that is causing the problem.
I was hoping that there is a way for me to determine the windows process id
or something else when I activate word and open the document. We are using
Word 2003 so it creates a separate process for each activation and open.
This is multiuser so I can't simply query the processes from Windows looking
for winword.exe. I most likely will get multiple processes for it. I need
a way to know which one is for the rogue process I want to kill.
Any help would be GREATLY appreciated.
TIA
Stephen
I am currently using VB to interface to WORD through COM. Basically, I am
creating a txt based mailmerge file, opening a specific mailmerge document,
merging it with created file, and printing it to a pseudo printer that
converts the document to a PDF file.
I have no control over the authoring of the mail merge document. This
process runs on a server non-interactively. I FULLY understand that Word is
not meant to run as a service process due to all the documented reasons and
MGMT understands it as well. However, we are where we are.
There are certain things that users can do that causes Word to absolutely go
crazy and end up eating tons of CPU. In fact, one user managed to created a
document that had very complicated table nesting within IFF conditions that
actually inadvertently generated unlimited number of print pages. They
kicked this off numerous times and brought the server to its knees.
I would like to be able to kill the Word process directly after a set time
to help protect the server. I can't do this through COM because it is
basically waiting on the merge/print to finish that is causing the problem.
I was hoping that there is a way for me to determine the windows process id
or something else when I activate word and open the document. We are using
Word 2003 so it creates a separate process for each activation and open.
This is multiuser so I can't simply query the processes from Windows looking
for winword.exe. I most likely will get multiple processes for it. I need
a way to know which one is for the rogue process I want to kill.
Any help would be GREATLY appreciated.
TIA
Stephen