Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
How to get rid of a child object in a class at runtime
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
00688718
Message ID:
00688754
Vues:
14
This message has been marked as the solution to the initial question of the thread.
Hi Armin,

>I have a framework container class which hosts another object as a child. I would like to replace the child object with my own.

You can only do this on the object level, not the class level. For example, f the object is part of an SCX, it works, otherwise it doesn't. Basically, if you can't remove an object in the designer, you can't do so at runtime. Even though VFP lets you remove the physical object, it doesn't let you remove the name entry for this object.

If you need to replace the object of the framework, you either have to redefine the class hierarchy, or modify the framework to use an object reference property to access the contained object.

Christof
--
Christof
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform