Menu Option Comment

When you open a menu in the VPM Enterprise Menu Builder, VPM Enterprise displays the menu in the Visual FoxPro Menu Designer. When you subsequently exit the Visual FoxPro Menu Designer, VPM Enterprise inserts code in the Comment of menu options if the code is not already there.

VPM Enterprise automatically inserts the following GENMENUX directive into the Comment of menu options that donít already have it. This directive activates VPM Enterprise Menu Security for the option.

*:IF _SCREEN.oApp.RunAdminTool(ĎSEC_MENUí,íMí, ĎOptionNumberí,íMenuNumberí)

The RunAdminTool method determines which tools are included or excluded from an application and which included tools are turned on.

The parameter SEC_MENU tells the RunAdminTool method to run an applicationís security routine if Menu Security is included in the application and if itís turned on. An applicationís security routine handles menu, form control, and Field Security. The RunAdminTool method passes the 2nd, 3rd and 4th parameters in the directive to the security routine. The security routine uses these parameters to find the Menu Security record for a menu option to determine a userís right to access the option.

The M parameter tells the security routine itís being called for a Menu Security check. This is necessary because the same routine handles menu, control, and field security.

The OptionNumber parameter is actually a number that uniquely identifies the menu option. VPM Enterprise automatically assigns unique numbers to every menu option you add to a menu.

The MenuNumber parameter is actually a number that uniquely identifies each menu in an application. VPM Enterprise automatically assigns unique numbers to every menu in the Menu Builder.

More:

When You Create or Add Menu files