XL5: Custom Macro Command Duplicated on Tools Menu

ID: Q124005


The information in this article applies to:


SYMPTOMS

In Microsoft Excel 5.0, when you write or record a macro, you have the option to run it from a command on the Tools menu. If you move or copy the macro, the command may appear more than once on the Tools menu. Note also that if you delete the macro, the command may remain on the Tools menu, and you will be unable to delete it.

CAUSES

You may have duplicate commands on the Tools menu when you do either of the following:

If you delete the macro and then choose the command, you will receive an error message. You receive an error message because Microsoft Excel is unable to find the macro.


WORKAROUND

To avoid the above problems, use the following guidelines when you assign macros to commands on the Tools menu:

To remove a macro command from the Tools menu

  1. Verify that the macro is in the workbook where the information has been saved. (If the macro has been moved to a different workbook, copy it back to the original workbook.)


  2. On the Tools menu, click Macro.


  3. Select the name of the macro that you want to change the options for, and click Options.


  4. Clear the Menu Item On Tools Menu check box.


NOTE: If you delete the macro before you remove the command from the Tools menu, the only way to remove the command is to re-create the workbook.


STATUS

This is a known problem in the versions of Microsoft Excel listed at the beginning of this article. The problem was corrected in Microsoft Excel for Windows 95, version 7.0, Microsoft Excel 97, and Microsoft Excel 98 Macintosh Edition.


REFERENCES

"Visual Basic User's Guide," version 5.0, Chapter 1, "Setting and Changing Macro Options"

"Visual Basic User's Guide," version 5.0, Chapter 12, "Menus and Toolbars"

For more information about Adding a macro to the Tools menu, choose the Search button in Help and type:


   commands, adding macros as 

Additional query words: 5.00a 5.00c XL5


Keywords          : kbcode kbmacro kbprg 
Version           : WINDOWS:5.0,5.0c; MACINTOSH:5.0,5.0a
Platform          : MACINTOSH WINDOWS 
Issue type        : 

Last Reviewed: April 18, 1999