Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Any builder to change the parent class once dropped on a
Message
De
12/02/2007 15:08:46
Mike Yearwood
Toronto, Ontario, Canada
 
 
À
12/02/2007 11:23:25
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01194379
Message ID:
01194862
Vues:
16
>Mike, some time, when you get a minute or two, tell me about a factory object, what it is and how to do it, please. Unless of course, you are speaking of out 'of the box' VFP objects.

Theoretically a factory object is the same thing as the food replicators on Star Trek TNG. You place an order for Tea, Earl Grey, Hot and the factory builds you one based on the "program" in its database in whatever container it was programmed to provide.

Now if you wanted to assemble a form class using classes you could do that in the designer easily. Try to undo that and put in different classes per client application. That's not easy without deleting the current content at runtime and replacing the controls with subclassed controls.

That would be like saying Tea Earl Grey in a gold chalice.

Having that in place, when you begin your next project, you can subclass your standard controls and the subclasses will be used in this project and a different set would be used in another project all from the same common "blueprint".

>
>Grady
>
>
>>Hi Bhavbhuti
>>
>>>Is there any builder out there that can help me change the parent class of a field once I have dragged-dropped onto the form? Or is hacking the vcx the only route?
>>
>>I would like to point out that a factory object approach can be used. You create a class. You dynamically add the field to the form through the factory. If you use a table for the factory the table can specify the class.
>>
>>Instead of trying to change things after the fact, make them dynamic from the start. This gives far more flexibility.
>>
>>Mike
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform