Can't start Outlook Instance while outlook client is running

Do you have a question? Post it now! No Registration Necessary.  Now with pictures!

Threaded View

I'm running WinXP,IE6.0 on my workstation and have a local server
running WInXP,Apache 2,MySQL 5,PHP 4.

I wrote this script to grab certain addresses from distribution lists
in an Outlook 2003 address book and throw them into a MySQL table.

It worked when I tested it in UltraEdit Studio and it works when I run
it from the command line.  But I need to run it from a browser or have
the browser batch it to the server to run from the command line.
When I tested it from a browser while the Outlook 2003 client was
running on the server, it gave me this error:

'Failed to create COM object `Outlook.Application': Server execution

So I build a little snippet to run some tests:

$ol = new COM("Outlook.Application","localhost");
print "done!";
and save it as testcom.php.

It works from the browser as long as the server doesn't have an
Outlook client open. But I need the client to be open sometimes.

If the Outlook client is open and I run it from the command line on
the server it works fine.

C:\PHP\php testcom.php

C:\PHP\php.ini and C:\windows\php.ini are identical.

I'm pretty sure I need the Outlook client open to get to the address
book.  Our exchange server is Electricmail.

Does anybody have any ideas on what is happening, how to get around it
or how to fix it?  THanks for any input.


Re: Can't start Outlook Instance while outlook client is running

Quoted text here. Click to load it

I would suggest accessing the address book over ADODB (through JET)
instead of using Office automation. Trying to control an Office app in
a server application is always going to be hairy. Accessing the data
store is relatively easy, on the other hand, with Jet as it provides a
SQL interface.

Site Timeline