Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Shall we always subclass base controls
Message
 
À
26/04/2000 20:31:45
Information générale
Forum:
Visual FoxPro
Catégorie:
Programmation Orientée Object
Divers
Thread ID:
00363904
Message ID:
00363924
Vues:
29
I always use a subclass for any control I use (even labels), except for those that can't be used in the visual designers. The reason is if you decide you want to add any kind of global functionality later. If you didn't subclass, you have to go to every instance of the object and put the functionality in each one. If you subclass, you can make the change directly in the subclass, and have it inherited to all the instances.


>Probably naive question and has been answered already. What benefits of subclassing base controls if I am not intending to extend their functionality or build an extensive framework. For instance I just want to use a form template ( pageframe with several pages and with a grid on one page and listbox on other). What benefits of using subclassed grid and listbox instead of base ones.
>
>What are the usual practices with VFP ?
>
>Thanks.
>Michael
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform