1. Home
  2. MS Office
  3. Create macros in word 2010

Create Macros In Word 2010

Macros has been an old phenomenon of Office apps allowing you to record set of actions you perform on document, and to repeat them in future. Through Macros, you don’t need to perform same action, i.e, change formatting, style, font family, size, and color over and over again in document. It actually records each and every click and keystroke you press while performing the task, so that you can play them back to perform same action over your documents.

To begin, launch Word 2010 and open a document to record a macro. For Illustration, we have included a document containing a paragraph. We will record a macro to automatically format the paragraph.

document 1

To record a Macro, navigate to View tab, and from Macros options, click Record Macro.

record macro

It will bring up Record Macro dialog, allowing you to enter a Macro name. Under Assign macro to options, click Keyboard button to assign a hotkey.

enter macro name

Now place insert cursor in Press new shortcut key box, and assign a hotkey by pressing keys combination. Click Assign to assign hotkey to macro, and then click OK.

assign button

You will see recorder-like image with pointer, indicating that macro is being recorded. We will do some formatting over the text like insert drop box, change paragraph color etc.

rewcording macro

To stop recording macro, head over to View tab and from Macro options, click Stop Recording.

stop recording

Now we will execute macro over new document to align with the formatting style we have applied earlier.

new document

Run the macro by pressing the specified hotkey. In our case, it is Ctrl+Shift+M. It will immediately apply recorded formatting style to the new paragraph.

run macro

For saving a macro-enabled document, on File menu, click Save as. From Save as dialog, under Save as type options, click Word Macro-Enabled Template (*dotm). Enter an appropriate name of document and click Save.

macro enabled

We have demonstrated recording a macro with simple steps and applied only basic formatting over the document. However , you could create a complex one to record tons of document design changes and formatting styles.

You can also check out previously reviewed guides on How to fill Word 2010 document with Auto-fill & How to change font color to Gradient fill.

21 Comments

  1. I am in highschool and I am in a computer class that I am failing so this came in handy to study for my test and I PASSED!!!!!!!!!!!!!!

  2. Worthless. Your View does not comport with the View and its parts on our 2010 Office.

  3. I am stuck in Virtual Basic Macro mode. I NEVER get the option to record or assign a macro to buttons or keyboard. When I go to MACROS it defaults to the VB Editor. How do I stop ths?

  4. Create a macro that applies a first line
    Indentation to text. Name the macro Indent and apply it to all Heading 1

  5. Create a macro that applies a first line
    Indentation to text. Name the macro Indent and apply it to all Heading 1

  6. This post should say where to save the docm so that when all Word docs are closed and one is reopened, the macro will still be available. Not obvious at all.

  7. Hi

    I want to create a Word Art macro in Office 2010

    But after I’ve made, it does not work
    anymore

    What should i do?

  8. I tried the above on a protected form and now I can’t protect the form.  Is there a way to do both?

  9. After I record a keyboard macro and save the file, the macros do not appear for use in future documents. The older version of Word they did!
    What to do?

    • Make sure you save the macro in Normal.dotm (might appear as just ‘Normal’ without dotm), because otherwise it isn’t included in normal startup.

    • I have the same problem, but when I save the file with macros I save it as a report.dotm and when I sent this to other to used none of the macros work.  Does this mean that I have to same the macros to the norma.dotm and also sent that along with my document in order for the macros to work. 

  10. Yesterday I was trying for the first time a macro in Word, and I didn’t put attention to the the instructions. Now every time that I open a Word document, there is a security message that says that the macros are disabled. It seems that I recorded a macro, but now I can’t erase it, because when I want to do so, it says that a Sub or function has not been defined. What can I do? I don’t want to see the same message every time that I want to use Word.

    • I had this problem whenever I open Word (or any document with Word). It complained that macros were disabled, security risk, blablabla. Then I remembered I chose not to install macro support during the initial setup. So I reinstalled Word with that feature enabled and whaddya know, it didn’t complain anymore.

    • With me it’s the same. In my Word 2007 it was everything ok, but now in Word 2010 everytime I open even a blank document it shows that yellow bar. I know it can be different because in my Word 2007 I recorded several macros and it doesn’t “alert” me of the risk, even though in the Trust center > Macro setting I set “Disable all macros with notification”, but I don’t know how to solve that problem.