Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Tastrade FrameWork
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00061667
Message ID:
00061824
Views:
36
>>>I am using the Tastrade's type of framework for my application. In the login form, which is created and run from the 'main::init()' method, I need to get access to an object that I created in the 'Application::Init()' class. The name of the object that I created is 'oRegistry'. The 'oRegistry' object is able to read and write data to the registry.
>>
>>Joseph, how did you create it? CREATEOBJECT or AddObject?
>>If it is added to oApp object you should call it oApp.oRegistry.myMethod()
>>If it is created with CREATEOBJECT you need to make sure that oRegistry was declared as PUBLIC variable first, to be accessible from any place.
>>
>>HTH, Nick
>I used AddObject. The problem is that oApp is not created yet as the login method in called in the 'Main' init method.
>But if I read your second suggestion corretly, is that I can create the 'oRegistry' object using the 'CreateObject' and then I can get access to it at any point, even if the 'Main' init method is not complete yet.

Yes, if you make it public variable and do it one of the first things in your start program.
Nick Neklioudov
Universal Thread Consultant
3 times Microsoft MVP - Visual FoxPro

"I have not failed. I've just found 10,000 ways that don't work." - Thomas Edison
Previous
Reply
Map
View

Click here to load this message in the networking platform