Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
DataEnvironment Subclass
Message
De
29/05/2003 17:22:57
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00794205
Message ID:
00794229
Vues:
15
>>>Can someone enlighten me, please? Is this the intent? If so, this class is durn-near worthless to me. TIA!
>>
>>Mark,
>>
>>Why don't you try to modify DE class outside of the form designer?
>>I believe you will get what you want.
>
>It would, but I do not want to have to create a DE subclass for every one of my forms depending on what data each form needs. I was wanting to create a DE subclass that contains the code I normally use in all form DEs. Then have each form use that DE subclass, but still have the flexibility to add whatever data objects to the DE subclass in the Form Designer. Creating a DE subclass for each different form DE is a pain when you consider I would have to close the form designer, edit the DE subclass in the Class Browser, then go back to the Form Designer.


Mark,

Aren't you failing to create those subclasses? You are trying to modify DE on the form, this means that you are trying to implicitly subclass it. This contradicts with your goal to avoid subclassing DE for each form.

The following approach should work for you:
1) Create UsualDE class with usual DE code.
2) For each form, create subclass of UsualDE and add cursors or CursorAdapters specific to the form.
3) Link each form to its DE subclass.

Thanks,
Aleksey.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform