Please Note: This article is written for users of the following Microsoft Excel versions: 97, 2000, 2002, and 2003. If you are using a later version (Excel 2007 or later), this tip may not work for you. For a version of this tip written specifically for later versions of Excel, click here: Getting Rid of the "Enable Macros" Notice.

Getting Rid of the "Enable Macros" Notice

Written by Allen Wyatt (last updated January 26, 2021)
This tip applies to Excel 97, 2000, 2002, and 2003


2

The VBA programming language included with Excel allows you to create very powerful macros. It is not uncommon to record a couple of macros for a workbook, each designed to accomplish a quick little task. When you create the macros, Excel adds what is called a module to your workbook. This module is used to store the macros that you record or create.

You may notice that every time you open a workbook that contains macros, Excel asks you if you want to enable the macros. This is part of the security system built into Excel. (This system has saved my bacon on more than one occasion.) You may also have noticed that if you delete all the macros in your workbook, Excel still asks you if you want to enable macros when you later open the workbook.

Why would Excel do this? After all, you deleted all the macros in the workbook, right? The reason is that the module automatically created by Excel to hold your macros is not automatically deleted when you get rid of the last macro—it's still there. As long as the module is there, Excel will dutifully ask you if you want to enable your macros whenever you load the workbook.

To overcome this problem (and get rid of the macro prompt for this particular workbook), follow these steps:

  1. Press Alt+F11 to display the Visual Basic Editor.
  2. Near the upper-left side of the editor is the Project Explorer. This contains a hierarchical tree that shows the different modules in your workbook. If the Project Explorer is not visible on your screen, press Ctrl+R to display it.
  3. Within the Project Explorer should be a folder called Modules. If it is not already open, double-click on the Modules folder to display its contents.
  4. Right-click on a module in the folder. A Context menu is displayed.
  5. Choose the Remove option from the Context menu. You are asked if you want to export the module before removing it.
  6. Click on the No button. The module is removed.
  7. Repeat steps 5 through 7 for each module in the Modules folder.
  8. Close the Visual Basic Editor.
  9. Resave your workbook.

At this point your workbook contains no modules, and you will not get any notification when you subsequently open it.

Note:

If you would like to know how to use the macros described on this page (or on any other page on the ExcelTips sites), I've prepared a special page that includes helpful information. Click here to open that special page in a new browser tab.

ExcelTips is your source for cost-effective Microsoft Excel training. This tip (2587) applies to Microsoft Excel 97, 2000, 2002, and 2003. You can find a version of this tip for the ribbon interface of Excel (Excel 2007 and later) here: Getting Rid of the "Enable Macros" Notice.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Spell-checking Uppercase Words

When Word checks the spelling of a document, it can either check or ignore words that are in uppercase letters. Here's ...

Discover More

Opening Multiple Documents at Once

Word's Open dialog box provides many of the same file management functions as Windows Explorer does. One of the functions ...

Discover More

Changing Text in Text Boxes on a Chart

Macros allow you to make changes to virtually anything you can see in Excel. This tip examines how to make changes (even ...

Discover More

Professional Development Guidance! Four world-class developers offer start-to-finish guidance for building powerful, robust, and secure applications with Excel. The authors show how to consistently make the right design decisions and make the most of Excel's powerful features. Check out Professional Excel Development today!

More ExcelTips (menu)

Unhiding or Listing All Objects

An Excel workbook can contain quite a few different objects. Sometimes those objects can be hidden so that they are not ...

Discover More

Running a Macro When a Worksheet is Deactivated

You can easily configure Excel so that it runs a specific macro whenever a worksheet is deactivated. Just follow the easy ...

Discover More

Using SUM In a Macro

Want to use a worksheet function (such as SUM) from within a macro? Here's how easy it is to accomplish the task.

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is 1 + 1?

2021-10-06 21:20:25

Joaquin Jimenez

But I want to keep my modules! I need to run my macros!


2018-05-17 14:48:36

Rebekah

Thanks for the advice! It worked amazingly and I have excel 2013!!!


This Site

Got a version of Excel that uses the menu interface (Excel 97, Excel 2000, Excel 2002, or Excel 2003)? This site is for you! If you use a later version of Excel, visit our ExcelTips site focusing on the ribbon interface.

Newest Tips
Subscribe

FREE SERVICE: Get tips like this every week in ExcelTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.