Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
IMPLEMENTS Statement
Message
De
25/02/2004 17:47:56
 
 
À
25/02/2004 17:18:52
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00880818
Message ID:
00880933
Vues:
30
>I would like to change the IMPLEMENTS statemany so that it gets
>it's DLL path from a function:
>
>I want to change:
>IMPLEMENTS _SomeEvents IN "c:\some.dll"

>
>What exactly are you trying to accomplish here? AFAIK, what you are trying to do is not possible because the IMPLEMENTS keyword is part of the DEFINE CLASS statement. This is from the VFP help file:
>
>
>IMPLEMENTS InterfaceName
>Specifies that this class definition inherits the interface (class definition) of another COM component. One class can include several IMPLEMENTS statements.
>DEFINE CLASS myClass AS custom olepublic
>   IMPLEMENTS Publisher IN "mybookstore.dll"
>   PROCEDURE Publisher_ShowPrice(cGetID AS Long) AS Short
>   ENDPROC
>ENDDEFINE
>
>
>Now, it seems to me, that because this defines an interface that your class inherits, you cannot turn this into a runtime activity any more than you could change the parent class of a subclass on the fly at runtime < s >.

That was my understanding, too, but - coincidentally - I've been going over some example code from Calvin and it looks like he's doing something tricky with IMPLEMENTS, but I can't figure it out: How does Calvin's code work? Thread #880866 Message #880866
Regards. Al

"Violence is the last refuge of the incompetent." -- Isaac Asimov
"Never let your sense of morals prevent you from doing what is right." -- Isaac Asimov

Neither a despot, nor a doormat, be

Every app wants to be a database app when it grows up
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform