This browser does not support basic Web standards, preventing the display of our site's intended design. May we suggest that you upgrade your browser?
A macro is a shortcut for performing a series of actions and is useful for automating complex or repetitive tasks. Macros are helpful if the work is being shared with someone else because it is easier to explain how to use a shortcut than it is to explain several steps. For a macro to be worthwhile, the series of actions you wish to accomplish must be consistent.
When creating a macro, planning can be very helpful. Knowing specifically what you want the macro to accomplish and in what order can save a lot of time, editing, and frustration. When the macro is saved, the information is stored as a part of the current template and will be available for all documents based on that template. You can also copy macros to documents based on other templates. For more information on tips for advanced macros and how to run, suspend, or delete macros, refer to Working with Macros.
As you are creating a macro, you will be requested to assign a name to the macro and to indicate where it will be stored. The following guidelines and tips can help you make the best decision.
Macro names must:
| AutoExec | The macro runs when Word is opened |
| AutoExit | The macro runs when you exit Word |
| AutoOpen | The macro runs when you open a document |
| AutoNew | The macro runs when you create a new document |
| AutoClose | The macro runs when you close the current document |
A macro is saved as part of a template. If you want the macro available whenever you use Word, the macro should be saved as part of the normal.dot template. However, if the use of the macro is limited to specific types of documents and you have a template for that type of document, it should be stored in that template.
While it is not required to assign a macro to a second location, doing so can make the macro easier to use and save more time. Depending on your personal style of working with Word, you may want to assign the macro to a keystroke combination, a menu, or a toolbar. You can assign the macro to all three if you want.
Macros can be created by recording keystrokes (not mouse actions like selecting text) or by writing the macro using the Visual Basic programming language. This document focuses on macros that can be created through the recording method.
WARNING: If you are working with a multi-layer dialog box (one with tabs at the top), only the changes on the current tab are recorded when you click OK. If you want to record changes on more than one layer, you will need to access the dialog box once for each layer, clicking OK as you complete the changes on that layer.
You can access the Record New Macro command through a menu or from a toolbar.
From the Tools menu, select Macro » Record New Macro
The Record Macro dialog appears.
If you would prefer to have the Record New Macro command available on a toolbar, follow the instructions:
Windows: From the View menu, select Toolbars » Customize...
The Customize dialog box appears.
Macintosh: From the View menu, select Toolbars » Customize Toolbars/Menus...
The Customize Toolbars/Menus dialog box appears.
Select the Commands tab
From the Categories scroll list, select Tools
From the Commands scroll list, click and drag MACROS... and RECORD MACRO/STOP RECORDER... to the Standard toolbar
NOTE: You may only click and drag a command to the toolbar one at a time.
Windows: Click CLOSE
Macintosh: Click OK
Windows: On the Standard toolbar, click RECORD NEW MACRO...![]()
Macintosh: On the Standard toolbar, click RECORD MACRO
The Record Macro dialog appears.
The Record New Macro command of Word creates macros using the Record Macro dialog box. Using this dialog box, you will name, describe, and assign the storage and access locations of the macro(s) you create.
Access the Record Macro dialog box
The Record Macro dialog box appears.

In the Macro name text box, type the name for the new macro
For information on naming conventions, refer to Naming a Macro.
OPTIONAL: In the Description text box, type a short narrative description for the macro
From the Store macro in pull-down list, select the appropriate option
NOTE: For more information, refer to Saving a Macro.
OPTIONAL: Assign the macro to a toolbar or keyboard combination
These options are covered in Assigning Macros to Additional Locations.
Click OK
The Macro Record toolbar appears in the window with your document.

Perform the activity that you want the macro to accomplish
When done, on the Macro Record toolbar, click STOP RECORDING
OR
From the Tools menu, select Macro » Stop Recording
The macro will be saved as part of the template you chose.
Continue with Running a Macro
The following instructions assume that you are assigning the macro to either a keyboard combination or a toolbar as part of the creating process (step 6 of Creating & Recording a New Macro).
Many keyboard combinations are already assigned to menu choices and dialog boxes. Below are the potential keyboard combinations you could use for a macro. It is often simply trial-and-error to locate the combination that will work for you.
NOTE: After entering the keyboard combination, a message will appear showing the assignment of the combination.
| Windows | Macintosh |
|---|---|
| [Alt] + [Ctrl] + character |
[ctrl] + [command] + character |
| [Alt] + [Shift] + character | [ctrl] + [shift] + character |
| [Alt] + [Shift] + [Ctrl] + character |
[alt] + [shift] + character |
| [Ctrl] + [Shift] + character | [command] + [shift] + character |
The following directions show you how to assign your macro to a keyboard combination.
Access the Record Macro dialog box
The Record Macro dialog box appears.
Under Assign macro to, click KEYBOARD![]()
The Customize Keyboard dialog box appears.

With your insertion point in the Press new shortcut key text box, press the keyboard combination that you want to use to execute the macro
NOTE: The shortcut will be displayed in the text box. The action currently associated with the shortcut appears under the text box. If you do not want to override the shortcut's original function, delete it from the text box and press another combination.
Click ASSIGN
Your shortcut key appears in the Current keys scroll list.
Windows: Click CLOSE
Macintosh: Click OK
Continue with step 7 of Creating & Recording a New Macro
Access the Record Macro dialog box
The Record Macro dialog box appears.
Under Assign macro to, click TOOLBARS![]()
Windows: The Customize dialog box appears.
Macintosh: The Customize Toolbars/Menus dialog box appears.
From the Toolbars scroll list, select the toolbar needed
Select the Commands tab
From the Commands scroll list, click and drag the macro name to a desired toolbar
Windows: Click CLOSE
Macintosh: Click OK
The Macro Record toolbar appears.

Perform the activity that you want the macro to accomplish
When done, on the Macro Record toolbar, click STOP
The macro will be saved with your template.

Click CLOSE