Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Public Variables or Object Properties
Message
From
24/05/2001 13:06:59
 
 
To
24/05/2001 12:46:09
General information
Forum:
Visual FoxPro
Category:
Object Oriented Programming
Miscellaneous
Thread ID:
00510878
Message ID:
00511050
Views:
19
>Craig
>
>>An excellent practice. You should also declare you application object as PRIVATE in your MAIN.PRG.
>
>Why should I use private? at the moment I have it as a Public.
>
>Kev

The main reason I can think of is this:
If you ever need to call one app from another app and they're both built on the same framework, they will probably have the same variable name for the application (e.g., Codebook uses goApp), the 2nd app will stomp on the first app's variable if it's Public.
If it's Private, it won't.
Insanity: Doing the same thing over and over and expecting different results.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform