Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How can I use a modeless form?
Message
General information
Forum:
Visual FoxPro
Category:
Forms & Form designer
Miscellaneous
Thread ID:
00501150
Message ID:
00501172
Views:
24
>>>>>>>>>>>>>>>>>
the reason I am writing, is that I dont know for sure if this is a good way of handling classforms... by creating public vars... it works, but something is telling me that is not, really a good solution.
>>>>>>>>>>>>>>>>>

You should stay away from PUBLIC vars as much as possible. They are not OOP, they break encapsulation and are a PITA to debug.

READ EVENTS is the correct way as Larry said.

You can replace PUBLIC vars by proper use of scoping (LOCAL vars and PRIVATE occasionally like for reports for example).

You can have global objects in an apllication class that you instance early in the loading of your program and that contains most of your utilities (like we used to do with SET PROCEDURE TO prg in procedural code).


Alex Feldstein, MCP, Microsoft MVP
VFP Tips: English - Spanish
Website - Blog - Photo Gallery


"Once again, we come to the Holiday Season, a deeply religious time that each of us observes, in his own way, by going to the mall of his choice." -- Dave Barry
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform