Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Order of instantiation
Message
 
 
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Versions des environnements
Visual FoxPro:
VFP 9 SP1
Divers
Thread ID:
01292155
Message ID:
01292158
Vues:
30
>>I am trying to understand the order of instantiation and how to use it.
>>
>>Here is an example:
>>
>>Form Class A (base class, based on VFP form class). This class has a method to manipulate form controls (textboxes, buttons, labels, etc.). Let’s call this method MYMETHOD1(). But Form Class A has NO controls.
>>
>>Form Class B (based on Class A, above). This form has controls (textboxes, labels, pageframe, etc.) I need to call method MYMETHOD1() in INIT method of this class (class B). Should I first call DODEFAULT() to make sure that all controls are instantiated before calling MYMETHOD1()? Or VFP instantiate all controls first, by default?
>>
>>Thank you in advance for any help.
>
>You can call this class method from the form's Init.

I know. But I would like to know if I should call DODEFAULT() in INIT method of the Class B before calling method MYMETHOD1() of Class A. Ideally I would like to call MYMETHOD1() in the INIT method of the Class A so that any class that inherits from class A automatically calls this method.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Précédent
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform