Page 1 of 1

Using COM with PHP

Posted: Thu May 20, 2004 7:05 am
by Delphin
I'm trying to use COM components in PHP script. I set the values in php.ini [com] section, added in dcomcnfg on server IUSR_MYHOSTNAME user to allow launch and access this COM(COM is on server), but when creating using new COM('My.Component') I receive

Unable to obtain IDispatch interface for CLSID {xx-xxxx...}: Server execution failed .

Maybe someone can help me ?

I'm using IIS6 + PHP4

Posted: Thu May 20, 2004 10:41 am
by feyd
the component you have sounds like it's not returning an IDispatch interface when asked to. Probably returning IUnknown or worse, nothing.

Posted: Fri May 21, 2004 1:28 am
by Delphin
No, it's ok with IDispatch. I'm trying to use word.application and excel.application and the practically same code is working in Visual basic 6 with no problem.

Posted: Fri May 21, 2004 1:36 am
by feyd
hmm.. it's been a while since I've used DCOM stuffs..