Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Have many buttons, want to save properties
Message
De
18/01/2008 08:59:39
Jay Johengen
Altamahaw-Ossipee, Caroline du Nord, États-Unis
 
 
À
18/01/2008 08:49:29
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Versions des environnements
Visual FoxPro:
VFP 8 SP1
Divers
Thread ID:
01282903
Message ID:
01282911
Vues:
9
>>I have a container class that has a row of command buttons. I have a need to save some of the properties of each button on intialization of the class. Doing one button was simple; just create the properties on the container. Now I need to do it for 10 buttons and I want to do it with the right approach. Creating button-specific properties on the container for 10 buttons doesn't seem like a good idea. Any ideas? Thanks!
>
>In the init of each button: This.addproperty('yourvar',yourvalue). The best is to create a common subclass for these buttons.

Ok, I rarely use the AddProperty in visual classes, but it makes sense. Thanks!

For extra credit: How can I change the baseclass of my buttons to reference a new baseclass button I create? Right now they are using the default Foxpro command button.

UPDATE: By the way, that worked like a charm! Thanks again!
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform