Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
GetObject once more
Message
General information
Forum:
Visual FoxPro
Category:
COM/DCOM and OLE Automation
Miscellaneous
Thread ID:
01071961
Message ID:
01071988
Views:
29
>In the remote computer DCOM is running ( calling by CreateObject ) all time I wona only call an existing instance this DCOM. It is possible ?
>
>Best regards

Ah! For this you need another trick, at least I solve this problem with a trick, not sure if there is a better way.

What I did was creating a Proxy Object which only mission is to return the running COM using GetObject (for this you need to solve the GetObject bug as pointed out earlier), this is an schematic of what I did:
[Computer 1 (Server)]   [Computer 2 (Client)]

myDCOM                  Create an Instance of myProxy in Computer 1 and thru it get a reference of the running myDCOM (Using CreateObject)
myProxy
----------------------------------------------------------------------------------------------------------------------

myProxy has only one method called getMyDCOM() that will make the actual call to GetObject(, 'myDCOM.Application')
In this way I am able to grab an instance of a COM object that is already running in a remote computer
"The five senses obstruct or deform the apprehension of reality."
Jorge L. Borges?

"Premature optimization is the root of all evil in programming."
Donald Knuth, repeating C. A. R. Hoare

"To die for a religion is easier than to live it absolutely"
Jorge L. Borges
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform