Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Variable Declaration
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Autre
Divers
Thread ID:
00028187
Message ID:
00028460
Vues:
37
-- snip --
>>BTW, I do use public variables for a few reasons.
>>
>>1. maintaining a global application object. GoApp
>>2. maintaining a user/security object. GoUser
>>3. a bailout flag for my error handler. glMustQuit
>>
>>
>>Greg Moss
>>gmoss@midwest.net
>
>Thanks Greg,
>
>Now I can say that I see the point of declaring variable through a property of a form. I have a few question for you if you don't mind too much (or to anybody else), is a controlsource considered a variable in a form? Or is it just a name you give to access the object value? By declaring a variable through a form property, is it possible to access this variable from a another form called by that form (where the variable is located)?
>
>Thanks,
>Yves

Yves, any form property can be considered a "variable" local to that form, but you'll find it easier to learn OOP programming if you think "property" (and controlsource is a property) instead of "variable". An object value is NOT the same as the control source. For example, a control might have controlsource = MyTable.Name, but the control.value can be "Barbara Paltiel" or "Yves Allaire" depending on the record.

As for your second question YES!! This is a VERY useful bit of programming, as it allows you to change a form from another form, where the second form might be a FIND procedure, a second data-entry form, a lookup form, etc.

HTH
Barbara
Barbara Paltiel, Paltiel Inc.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform