Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
How Do I Start the Event Model When No Menu is Used?
Message
General information
Forum:
Visual FoxPro
Category:
Coding, syntax & commands
Miscellaneous
Thread ID:
00109592
Message ID:
00109953
Views:
22
>>Greetings!
>>
>>I want to create a VFP form that can be popped up from a FPW26 application. The form works great as-is, however, without the READ EVENTS statement, it immediately closes. Normally, I would load a menu and then issue READ EVENTS, but in this case, I don't want another menu loading. If I set up an ON KEY LABEL before the READ EVENTS, I can load the form with a keystroke, but that should not be necessary.
>>
>>Therefore, is there a way to have the event model running when the form is loaded, without using a menu? Can the event model be started from within the form?
>>
>>Thanks!
>>
>>Michael Reynolds
>>Santa Barbara, CA
>Michael,
>
>Make a startup program that Does your form and then issues a READ EVENTS.

Thanks for your reply, Jim. I found that it also works by making the form modal, based help from Garrett, since it's the only one that will be loaded.

However, I have another question which I hope you can answer. As I mentioned, this VFP form will be popping up from a FPW26 menu. I cannot call it as a "DO formname" since FPW26 cannot process the VFP code, so it needs to be called as a "RUN". If I simply say "RUN formname", it first opens a DOS window and then loads the VFP form, which looks quite choppy. The other way, which seems to work well, is by issuing "RUN /N1 formname" which opens it as a window.

The trouble is that /Nn means non-stop and, even though the VFP form loads, control is switched back to the FPW26 program, meaning that one would need to ALT+TAB to get to the VFP form. Do you know of a way to pop up the VFP form and keep it displayed?

Thanks again for your reply!

Michael Reynolds
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform