Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Menu Options Disabled With A Modal Form
Message
Information générale
Forum:
Visual FoxPro
Catégorie:
Gestionnaire de menu & Menus
Divers
Thread ID:
00319305
Message ID:
00319388
Vues:
12
>I have a modal from which I would like to select other menu options that do not involve leaving the current modal form (eg perform a calculation and display the results in a wait window)
>Is this possible. ( I Know I can do this via a button on the form if required).

Craig B. posted this a while back:

"The standard way is to provide the functionality with buttons or shortcut menus, but it
CAN be done with the regular menu. First, create menu pads that you want to have
available, such as Edit, Help, etc. These should replace the menu pads of your standard
menu. Place code in the following form events:

Activate:
PUSH MENU _MSYSMENU

GotFocus:
DO Edit.Mpr
DO Help.Mpr

Deactivate:
POP MENU _MSYSMENU"

The caveats here are that if you use custom toolbars, they will not function, and so your app will have an out-of-sync interface. And, there must be at least one modal-form control that receives the focus for it to work. Otherwise, it works fine.

A third caveat from a bug in vfp6 SP3 is that there is a caching problem for same-name programs, so you should probably NOT use the names Edit & Help as above, call them something slightly different.
The Anonymous Bureaucrat,
and frankly, quite content not to be
a member of either major US political party.
Précédent
Répondre
Fil
Voir

Click here to load this message in the networking platform