|
Posted by Alex on 11/14/07 18:32
"Alex" <d_keyoke@hotmail.com> wrote in message
news:473b3bee$0$30024$426a74cc@news.free.fr...
> "Steve" <no.one@example.com> wrote in message
> news:odG_i.89$qJ1.84@newsfe06.lga...
>>> It's from a software vendor. I meant to say that I have doc with the
>>> object, but all the examples of object usage are in VB, which I have
>>> long forgotten. They use lists, for example all around the place, and I
>>> don't remember how to translate this to PHP :)
>>
>> so, you know the object's interfaces...just not how to code it in php?
>> same way as any other object...
>>
>> $o->interface;
>> $o->interface(param);
>
>> etc.
>>
>> am i missing something?
>
> I'm pretty sure you're missing a lot less than I do :)
>
> But it's getting better. I replaced "new COM()" by com_load() and now I
> can use com_print_typeinfo which returns all the innards of the object. I
> don't really know why com_load works better, but it is the case.
>
> I also got to access one of the lists in the object. $....->item($i) . I'm
> not sure whether it's a special syntax instead of item[$i] or those
> item()s are really functions.
>
> So things are getting better :)
>
>
> However, my next blocking point is something called a factory. It is a
> property of my COM object that is itself an ever-existing instance of a
> class containing other objects. I think it is instanciated automatically
> by the COM server when I create the object.
>
> Everytime I put its name in my code ( $a =$obj->Factory; nothing more ),
> Apache bombs with no explanation.
>
> I have put the memory limit for PHP to 128M just to see but it doesnt
> change anything.
Oh there's something I just realized.
This "factory" object is an instance of a class called Factory. But the doc
also makes mention of something called an interface (IFactory) who has the
same methods/Properties of the class. When I do a com_print_typeinfo on the
Factory, I get almost nothing :
class Factory { /* GUID={F4E856D4-FCD7-11D4-9D8A-0001029DEAF5} */
}When I do it on the interface, I get all my object's properties.
There HAS to be a difference :)
--
Alex
[JDR] Visitez Extremia, un monde gratuit et en francais pour D&D et
autres jeux de role.
www.extremia.org
Navigation:
[Reply to this message]
|