Re: COM and MSWord Automation
- From: rob02omni@xxxxxxxxxxx
- Date: Tue, 2 Sep 2008 07:26:19 -0700 (PDT)
On 2 Set, 14:46, "Dale" <the....@xxxxxxxxxxx> wrote:
<rob02o...@xxxxxxxxxxx> wrote in message
news:c5a925d0-8629-404e-9d01-296c56ec3d74@xxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
Hi there!
I'm trying to automate MSWord in the server side.
For limiting memory usage i'm writing code to make a unique instance
of winword and then calling it from the php page i need.
So far i've used the sleep() function to keep alive the winword
instance but i think it would be better to use com_message_pump and
com_event_sink to take care of the winword process.
Alas when i try the code with com_event_sink function winword get
stuck?
Anyone has already tried something similar and/or has good example of
a winword daemon or similar?
uhmmm, 'daemon'? winword? you are mixing linux and windows terms. what's
your config? are you running php on linux and creating the word instance on
a remote windows server, or are you running everything on the same
pc/server - a windows server?
you do realize that php may or may not be running in the same process thread
each time an http request is made, right? are you familiar with
cross-process development in windows?
Hi and thanks for the reply.
Well i'm in a win32 server box, and as 'daemon' yes i was meaning a
service (or something like act as it).
I need to make mailmerge (i know of xml classes but i cant do this
because template are manipulated in clients) on the server and i have
realized that using multiple instance of winword will be a wast of
system resources (CPU, memory...).
What i want to accomplish is to have a php script running the COM
winword instance (for a period ie sleeping for accomplish tasks) and
making call with com_get_active_object.
I was thinking that the best practice would be to use com_message_pump
but i'm not really sure about this?
Thanks!
Rob
.
- References:
- COM and MSWord Automation
- From: rob02omni
- COM and MSWord Automation
- Prev by Date: Re: gethostbyaddr() bottleneck?
- Next by Date: Re: $_SESSION remains when browser is closed
- Previous by thread: COM and MSWord Automation
- Next by thread: Re: COM and MSWord Automation
- Index(es):
Relevant Pages
|