Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Create member in code before other members instantiate
Message
De
01/09/2009 16:53:31
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Versions des environnements
Visual FoxPro:
VFP 9 SP1
OS:
Windows XP SP2
Divers
Thread ID:
01421954
Message ID:
01422230
Vues:
82
>Hi Dragan,
>
>I see. Loading a class dynamically at a later time is your problem. The way I implemented this in one of the frameworks is to instantiate these objects through a factory. The factory would receive an ID, look up the definition and find that it needs to instantiate two classes. One is the data environment, one is the actual class. The DE was made available through a property and (for the duration of the Init) through a private variable.

Which works fine with one per form. However, I have multiple, and so I don't have the luxury of using .load() to do such work, and the loader object placed on the grandest parent container class doesn't guarantee to be instantiated first, not anymore.

Anyway, calling the factory via an expression in the property does work, so we have another trick up our sleeve :).

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform