Datasheet
Book IX
Chapter 1
Recording and
Using Macros
531
11. Test the macro.
If you assigned the macro to a keyboard shortcut, use the shortcut now
to see whether the macro works. Otherwise, follow the steps in the later
section “Running a Macro.”
12. You’re finished.
Congratulate yourself.
If the function of the macro isn’t obvious from the macro name, type a more
elaborate description of the macro in the Description field of the Record
Macro dialog box. You’ll thank yourself later when you forget what the
macro does.
Macro Recording Tips
Here are some tips to keep in mind as you record macros:
✦ You can open the Record Macro dialog box directly by clicking the
Record Macro button on the status bar. It appears as a little red dot.
✦ If the macro doesn’t work, you might have made a mistake while record-
ing it. If the macro is short enough, the best thing to do is to record the
macro again. If the macro is long and you have nothing important to do,
try editing the macro to expunge the problem. See the section “Editing a
Macro,” later in this chapter.
✦ Macros are normally stored in the global Normal.dotm template. To
store a macro in the template attached to the current document, change
the setting of the Record Macro dialog box’s Store Macro In drop-down
list.
✦ Don’t make any assumptions about where the insertion point will be
when you run the macro. If necessary, begin the macro with a position-
ing command by moving the insertion point to the beginning of the
document, the beginning of the line, or the beginning of a word. (Not all
macros require a positioning command. But if your macro depends in
any way on the position of the insertion point, this step is a must.)
✦ Don’t use the mouse to select text or navigate the document. Word
doesn’t record these mouse actions. You can use the mouse to select
Ribbon commands but not to move the insertion point.
✦ Use Ctrl+Home or Ctrl+End to move to the beginning or end of a docu-
ment. Don’t use repeated Page Up or Page Down keys for this purpose.
Pressing Page Up three times might move you to the top of your docu-
ment when you record the macro, but when you run the macro, it might
not. Similarly, use the Home and End keys, rather than the left or right
arrow keys, to move to the start or end of a line.
Macro Recording Tips
50_487662-bk09ch01.indd 53150_487662-bk09ch01.indd 531 4/15/10 9:18 PM4/15/10 9:18 PM