Can't Edit Macros

Written by Allen Wyatt (last updated March 27, 2021)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, and Word in Microsoft 365


3

Patricia recently upgraded from Word 2007, and some of her macros need editing. However, the Edit button in the Macros dialog box is grayed out. She wonders what she can do to edit her macros.

There are a few things to check, Patricia. The first thing you'll want to do is to figure out where your macros are stored. If the macros are stored in a document, make sure that you save the document (use Save As) as a DOCM file. If you save it as a DOCX file, the macros will be stripped from it. If it is in a DOCM file, then you will be able to edit your macros.

If the macros are not stored in a document but are, instead, in a template, then you'll want to load your template directly and save it back out (again, using Save As) as a macro-enabled template. Only then will you be able to modify the macros in the template.

The other thing you'll want to check is the security settings on your system. This is done by going to the Trust Center. Follow these steps:

  1. Display the Developer tab of the ribbon.
  2. Click the Macro Security tool, in the Code group. Word displays the Trust Center dialog box.
  3. Make sure Macro Settings is selected at the left of the dialog box. (This option should be selected by default.) (See Figure 1.)
  4. Figure 1. The Trust Center dialog box.

  5. Click the Enable All Macros radio button.
  6. Click OK.

Now when you open the problem document, you should be able to edit the macros.

A word of caution: These steps basically let any macros run on a system. If you are confident in your ability to not open any documents containing malicious code, then you are fine. If you routinely open documents from others who may be oblivious to such code, then you'll probably want to rerun the same steps and, in step 4, choose a more restrictive option such as Disable All Macros with Notification. While macros (and macro editing) will be disabled, you can still choose to run a macro by clicking a rather obvious button that will appear above the document—once it is loaded—and just below the ribbon.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (8381) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, and Word in Microsoft 365.

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

Editing AutoCorrect ACL Files

Information used with the AutoCorrect feature is stored in what is known as an ACL file. You normally edit this file by ...

Discover More

Extending a Paragraph into the Left Margin

Word allows you to format a paragraph so that it extends into the left margin of the document. This is done by setting a ...

Discover More

Ensuring Conditional Formatting and Data Validation is Copied

If you use an Excel worksheet for entering data (a quite common task, actually), then you need to be concerned with how ...

Discover More

Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!

More WordTips (ribbon)

Saving Search and Replace Information in a Macro

You may want to save a user's existing Find and Replace settings before changing them in your macro. This tip examines ...

Discover More

Changing Roman Numerals to Arabic

In some documents Roman numerals might be used quite a bit. If you ever want to change the Roman numerals to their Arabic ...

Discover More

Removing a Directory

Your macro, in the course of doing some processing, may create a directory that you later need to delete. Here's how to ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, 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 three less than 9?

2022-10-07 07:07:32

T.G. Johnson

After many weeks of frustration, phone calls, and googling, I found an easy way to fix this.

Make your macros in a Word DOC document.

They will then automatically work on any DOCX document.

I am not a techie, just a really annoyed author who needs my shortcuts.


2022-09-21 04:15:04

Ken

Documents containing macros that come from the Internet or a risky source may be blocked. To unblock them save the document then right click on the file name and select Properties. There will be an option to unblock.


2022-09-20 14:53:55

Mario J Salazar

I have tried this and many other things and Word will not allow me to use my Macros since this month. Apparently Microsoft instituted a change that macros from the internet would be disabled by default, but it seems it has given me no tools in allowing the macros I have been using for years.. They remain disabled even though I put their location as OK in the trust center and they are not on a network. Even without doing this, your solution should work, but sadly it does not.This is really frustrating.


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Videos
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, 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.