Help!!!! PHP and COM

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
doodle
Forum Newbie
Posts: 11
Joined: Sun May 04, 2003 1:45 am

Help!!!! PHP and COM

Post by doodle »

Please help me!!!

I tried using COM in my PHP pages. I tested to call Word program from PHP references. A warning appearing as following:

Warning: (null)(): Unable to obtain IDispatch interface for CLSID {000209FF-0000-0000-C000-000000000046}: visit refused. in F:\Web\PHP_Extensions\COM_Word.php on line 3
Unable to instanciate Word

I developed a simple DLL using VB and it worked. But some days later it stopped working. Similiar warning appeared as following:

Warning: (null)(): Unable to obtain IDispatch interface for CLSID {F65C23C1-BC04-474C-A7CC-E5D31DC12F66}: visit refued. in F:\Web\PHP_Extensions\COM_YJW.php on line 5
Unable to instanciate TestDll Plus

Actually now I can call functions from TestDll Plus in VB and Word. Than means the DLL and Work work well. In addition, Some other DLL I developed are working well.

Could some people tell me what the reasons are and How I can debug them???

Thanks in advance.
User avatar
twigletmac
Her Royal Site Adminness
Posts: 5371
Joined: Tue Apr 23, 2002 2:21 am
Location: Essex, UK

Post by twigletmac »

Have you got all the service packs installed for Office? I know there are some problems with accessing COM using PHP without these.

Mac
doodle
Forum Newbie
Posts: 11
Joined: Sun May 04, 2003 1:45 am

Thanks

Post by doodle »

Thanks, Mac:

I don't know the which model of the Office software should be installed. Do you know the reason that the DLL I developed for testing which worked before now stopped working???? I didn't change anything.

Thanks again.

doodle
User avatar
Stoker
Forum Regular
Posts: 782
Joined: Thu Jan 23, 2003 9:45 pm
Location: SWNY
Contact:

Post by Stoker »

Visual Basic does not make real DLL's, the runtime libs need to be in place (at least up to version 6).. Not sure if understand the need of doing word functions from a php script tho..
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

word

Post by Burrito »

I found a way to invoke a word instance using com to dynamically create word documents. But I'm struggling with being able to keep the instance of Word open on the server so that it doesn't require the server to invoke a new instance every time I try to generate a document.

Wondering if you ever found a solution to this. I'm more than happy to provide what I've got for you.

If you did ever find a solution to this, were you able to keep the instance of Word open?

thx,

Burr
malcolmboston
DevNet Resident
Posts: 1826
Joined: Tue Nov 18, 2003 1:09 pm
Location: Middlesbrough, UK

Post by malcolmboston »

thats 3 posts youve revived......... :?

people seen the first post
User avatar
Burrito
Spockulator
Posts: 4715
Joined: Wed Feb 04, 2004 8:15 pm
Location: Eden, Utah

word

Post by Burrito »

indeed it is. However, I'm hoping that these last two will get emailed to the participants (in case they don't check these forums every day) and provide a solution since you could not.

thx,

Burr
User avatar
ol4pr0
Forum Regular
Posts: 926
Joined: Thu Jan 08, 2004 11:22 am
Location: ecuador

Post by ol4pr0 »

If they wont check the forum everydays. there is always the @mail me when a reply has been submitted or something like that.....

If a post is that importent i think they will look it up / or have the @mail me enabled ;-)
Post Reply