Client declares an object-variable of a class defined inside a In-Process-Server (Active-X-dll).
If the project wouldn't be splitted into Client and Server i could get my Pointer without problem, because my object-variable is public for Project.
Right now i'm solving this with an byref-argument during a calling of a class-method for the first time (example: Set MyClass=AnotherObject.DoSomething(argWhatShouldYouDo, MyClass))
Now: As we should all know, all COM-Objects/Classes (and VB is COM!!) are derived fro IUnknown, which implements three invisible methods: AddRef, Release, QueryInterface.
IF i understand the msdn correctly, QueryInterface should give me an Array of pointers, which would actually be all variables i declared "as CMyClass".
Now, any ideas to get this Information from QueryInterface (Position 1 in the vtable of each COM-Object/Class) without doing some Hardcore hacks (Actually, there is a hack from Bruce McKinney i'm using to implement the "For each Next"-Feature in a Collection-Class of my on design, without using an internal Collection object (I'm using an array of variants))?
If there are no ideas, could at least somebody tell me, how an API-Like Declaration of IUnknown::QueryInterface would look like?
"Declare QueryInterface Lib blabla.dll (Arguments ByVal/ByRef.....)"
I'm especially interested, how the Arguments would look like. Right now i found out (ByVal Arg1 as GUID, Byval pointers() as variant)
In the C++-Headers:
Any Help is appreciated!
Only stupidity of mankind and the universe
are infinite, but i'm not sure concerning
the universe. A. Einstein