Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Subclass class in PRG file
Message
De
22/06/2018 08:44:43
Dragan Nedeljkovich (En ligne)
Now officially retired
Zrenjanin, Serbia
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Classes - VCX
Divers
Thread ID:
01660806
Message ID:
01660828
Vues:
89
>>Of course, one could argue if your subclass shouldn't be looking for a form in its class hierarchy, and only issue Thisform when it found one.
>
>Thank you, Antonio. For now I will leave the code with "thisform" in a method of this class (since it works). But when time permits I will see if I can review/change this. Just FYI, this is a class that connects to FTP for a file download. And the form has a progress bar. So the class (via updatebuffer method) calls the progress bar to update and show the progress.

The difference is that createobject() and newobject functions will create standalone objects, while .addobject() and .newobject() methods of a form or any of its members which have those methods will create a member object in form's containership hierarchy. Member objects have .parent objects, and ultimately up this hierarchy there would be a form which can be referenced as thisform. Unless, of course, your top container object is something else (custom, session etc).

back to same old

the first online autobiography, unfinished by design
What, me reckless? I'm full of recks!
Balkans, eh? Count them.
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform