StartupShortcutMenuBar Property

Microsoft Access Visual Basic

Show All

StartupShortcutMenuBar Property

   

You can use the StartupShortcutMenuBar property to specify a custom shortcut menu to use as the global shortcut menu for your application. You can also specify a menu bar macro that displays the custom shortcut menu you want to use as the global shortcut menu.

Setting

The StartupShortcutMenuBar property is a string expression that's the name of a custom shortcut menu or a menu bar macro that displays a custom shortcut menu.

The easiest way to set this property is by using the Shortcut Menu Bar option in the Startup dialog box, available by clicking Startup on the Tools menu. You can also set this property by using a macro or Visual Basic.

To set the StartupShortcutMenuBar property by using a macro or Visual Basic, you must first either set the property in the Startup dialog box once or create the property in the following ways:

Remarks

If you are setting the StartupShortcutMenuBar property, you shouldn't use a SetValue action in the AutoExec macro to set the ShortcutMenuBar property for the Application object. Since Microsoft Access runs the AutoExec macro after it parses the startup properties, the global shortcut menu set in the AutoExec macro would replace the shortcut menu set in the StartupShortcutMenuBar property.

You can also create custom shortcut menus by using the ShortcutMenuBar property for forms, reports, and form controls. These custom shortcut menus are displayed when you right-click a specific form, report, or form control, and replace the global shortcut menu in those cases.

If this property is blank, Microsoft Access displays the built-in shortcut menus.

Setting this property has the same effect as setting the ShortcutMenuBar property of the Application object (except the ShortcutMenuBar property setting takes effect immediately).

This property's setting doesn't take effect until the next time the application database opens.