Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Public and Private memvars
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Codage, syntaxe et commandes
Divers
Thread ID:
00121132
Message ID:
00121138
Vues:
17
Variables you create in your main program should be available to your forms unless they've been declared private or local somewhere along the line. It's not usually considered good practice to have a lot of public variables around, but sometimes it's unavoidable.

Is it possible that your application is running to completion and you're left with your menu and the command window showing. If so, you should use READ EVENTS to create a wait state in your application. This way, the variables will remain in scope because your main program will not have finished executing when your forms run.

>In the world of FoxPro 2.6 for DOS I could memvars in my main startup prg and they would be avalable in all parts of my app. I am having trouble understanding how vars work in VFP. Is there any simple rule(s) or can anyone tell me of a good reference source? I would like to create them in the main prg and then change them in forms. I can't understand what I am doing wrong.
>
>ps. Thanks all the people who have been helping an old DOS programmer come out of the stone age.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform