Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
My project is turning into a Monster
Message
General information
Forum:
Visual FoxPro
Category:
Other
Miscellaneous
Thread ID:
00241504
Message ID:
00241819
Views:
13
>>>I did a quick test and what happened when I called another .APP was that it returned to the READ EVENTS in the calling .APP. The result was that it was no longer able to reference the forms and programs in the called .APP.
>>>
>>>How do I get the focus to stay in the called .APP?
>>
>>One way that works:
>>
>>Have the main .PRG in the .APP just do a RETURN. Now, all the Forms, .PRGs, etc, are available to be called.
>>
>>So from your main .APP, you make 2 calls.
>>1) DO otherapp.APP
>>2) DO FORM forminotherapp
>>
>>This should keep all the functions from your main .APP available, and give you access to things in the other .APP as well.
>
>Fred,
>
>I tried your suggestion and it worked perfectly for any .PRGs I called. However, when I call a form I get a message that the form does not exist. The form is definitely included in the called .APP but does not exist in the calling .APP. This is exact same situation as the .PRGs yet for some reason it does not work. Any further ideas?
>
>Thanks in advance.

Hmm, I really don't know. That's the way we used to do it, and it worked for both .SCXs and .PRGs. We've since switched to all of our forms are classes in .VCXs, so we don't do it that way anymore. We switched for simplicity sake, so now we don't have hundreds of .SCX/.SCT files floating around.

I guess what you could do is make your main .PRG of your OtherApp, receive a parameter of what form to run and have it start the form. It should certainly be able to do that, but I haven't tried it that way.

Main.PRG for OtherApp.PRG
LPARAMETER tcFormName
DO FORM (tcFormName)
RETURN
Fred
Microsoft Visual FoxPro MVP

foxcentral.net
Previous
Reply
Map
View

Click here to load this message in the networking platform