Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
VFPCOM utility
Message
De
29/02/2000 16:43:38
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Titre:
Divers
Thread ID:
00338633
Message ID:
00339413
Vues:
30
>Why are are fixated on the COM Server having access to the calling process's private datasession is beyond me.

We are so fixated on it because that's what VFPCOM does. It does not USE the table, it just sees the one that is open in the current datasession of the VFP process that called it. This is not everyday COM stuff.

This thread originated with "how does VFPCOM do that?". This question was asked so that the asker could write some functionality similar to that, and so far, the question has not been answered.

>That is the most basic I can make the scenario....

Except that the scenario you have presented does not address the question. Try this to make it even simpler:

DEFINE CLASS TestCOM AS Custom OLEPUBLIC
FUNCTION GetRecCount
LPARA tcAlias
SELECT (tcAlias)
RETURN RECCOUNT()
ENDDEFINE

Compile this into a COM server, and call it from VFP's command window:

USE c:\SomeTable ALIAS SomeTable
oTC = CREATEOBJECT("TestCom.TestCom")
lnRecCount = oTC.GetRecCount("SomeTable")
?lnRecCount

It doesn't work, because Datasession information does not cross COM boundaries, but somehow with VFPCOM, it does. That's the question.
Erik Moore
Clientelligence
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform