ACC2000: Cannot Rename or Delete Custom Shortcut Menus (207854)



The information in this article applies to:

  • Microsoft Access 2000

This article was previously published under Q207854
Moderate: Requires basic macro, coding, and interoperability skills.

This article applies to a Microsoft Access database (.mdb) and to a Microsoft Access project (.adp).

SYMPTOMS

If you create a custom shortcut menu, you are unable to rename or delete the menu until you change its Type property setting to Toolbar.

RESOLUTION

To rename or delete a custom shortcut menu, you must first change its Type property back to Toolbar. You may also delete the shortcut menu by using Visual Basic for Applications code in the Immediate window.

CAUTION: If you follow the steps in this example, you modify the sample database Northwind.mdb. You may want to back up the Northwind.mdb file and follow these steps on a copy of the database.

Method 1: Changing the Type Property

NOTE:The following steps assume that you have created the shortcut menu Custom 1, using the example from the "More Information" section below.
  1. Start the application in which you created your custom shortcut menu. For this example, start Microsoft Access and open the sample database Northwind.mdb or the sample project NorthwindCS.adp.
  2. On the View menu, point to Toolbars, and then click Customize.
  3. On the Toolbars tab, click Properties.
  4. Click Custom 1 in the Selected Toolbar list.
  5. Click Toolbar in the Type list, and then click Close.
  6. On the Toolbars tab, click Custom 1 in the Toolbars list. Note that the Rename and Delete buttons are now available in the Customize dialog box.

Method 2: Using Visual Basic for Applications Code in the Immediate Window

  1. Open the Immediate window by pressing CTRL+G.
  2. Type the following line in the Immediate window

    Application.CommandBars("Custom 1").Delete

    and then press ENTER.

    Note that the Custom 1 shortcut menu is deleted.
You need to be cautious about using this method because there is no confirmation dialog box allowing you to choose not to delete the shortcut menu.

MORE INFORMATION

Steps to Reproduce Behavior

  1. Start Microsoft Access, and then open the sample database Northwind.mdb or the sample project NorthwindCS.adp.
  2. On the View menu, point to Toolbars, and then click Customize.
  3. On the Toolbars tab, click New. Name the new toolbar Custom 1.
  4. On the Toolbars tab, click Properties.
  5. Click Popup in the Type list. Note that you receive an informational message. Click OK.
  6. Click Close in the Toolbar Properties dialog box.
  7. On the Toolbars tab, click to select the Shortcut Menus check box under Toolbars. This displays the Shortcut Menus toolbar.
  8. On the Shortcut Menus toolbar, click Custom 1 on the Custom menu. Note that the Rename and Delete buttons are unavailable in the Customize dialog box.

REFERENCES

For more information about pop-up or shortcut menus, click Microsoft Access Help on the Help menu, type work with menu bars and shortcut menus in the Office Assistant or the Answer Wizard, and then click Search to view the topic.

Modification Type:MajorLast Reviewed:6/28/2004
Keywords:kbprb kbui KB207854