Microsoft KB Archive/110479

{| = How to Prevent Access to a System Menu from a Screen =
 * width="100%"|

ID: Q110479

2.50 2.50a 2.50b | 2.00 2.50 2.50a 2.50b

WINDOWS         | MS-DOS kbprg The information in this article applies to:


 * Microsoft FoxPro for Windows, versions 2.5, 2.5a, and 2.5b
 * Microsoft FoxPro for MS-DOS, versions 2.0, 2.5, 2.5a, and 2.5b

SUMMARY
When you are combining a menu and a screen, you can prevent access to all or some of the menu options, as described below.

To Disable Portions of the Menu System
Using the following steps, you can disable specific pads, popups, or bars of popups in a menu system.

NOTE: This procedure can be used in conjunction with or instead of a READ MODAL command.

1. In the Menu Builder, create the menu system.

2. Select the item you want to disable.

3. Select the Options box. In the Prompt Options dialog box, select the

Skip For check box, and type the following as the Skip For expression:

RDLEVEL>1

NOTE: If the application is not controlled by a foundation READ, the expression should be:

RDLEVEL>=1 4. Repeat steps 2 and 3 for every item that needs to be disabled.

To Disable the Entire System Menu
NOTE: This procedure can be used in conjunction with or instead of a READ MODAL command.

1. Create the screen you want to combine with your menu system.

2. Add a WHEN clause to the READ command. It should be marked as a

Procedure and contain the following command to disable the system menu:

SET SKIP OF MENU _MSYSMENU .T. 3. In the screen's Cleanup code, add the following command to activate the system menu again:

SET SKIP OF MENU _MSYSMENU .F.