Free computer Tutorials

home

 

Microsoft Word Macros

What is a Macro?

A macro is a shortcut to a task you do repeatedly. Think about the Centre align operation. You first highlight the word you want centred, then click the centre icon in the toolbar. This is a macro. It's the short way of performing the centre task.

But you don't have to do it that way. There is a longer way. You can centre your text by clicking on Format from the menu bar. When the menu drops down, click Paragraph. You'll get a dialogue box popping up. Click the down arrow in the Alignment box, and then click on centre. Click OK on the dialogue box and your text is centred. That's the long way round.

Clicking the centre icon on the toolbar is much easier - it's a very useful Macro built in to Microsoft Word.

A Macro is a way to create a shortcut for a task that you do a lot.

You can create your own macros. The macro we're going to create in the next section is a very simple one, but macros don't have to be simple. You can open up the Visual Basic editor and create a very complex macro indeed. Some malicious people even create Word macros that can do very nasty things to your computer!

So, after that little scare story, let's create our very own macros. This one is very simple, and definitely won't set off the alarm bells in your Anti-Virus software.

 

Our Macro

The macro we're going to create will format some text for us. After all, it's such a chore to highlight text then open the Font dialogue box. Once the Font dialogue box is open we then have to choose a Font, decide whether or not we want Bold, and then pick a size. The dialogue box then has to be closed. Much better to write a macro to do all that for us.

In case it's not clear what we want the macro to do, here's the long version of formatting the text.

  1. Highlight the text you want formatting
  2. From the menu bar, click on Format
  3. From the drop down menu, click on Font
  4. The Font dialogue box appears
  5. Choose Arial as the Font
  6. Click on Bold
  7. Click on 16 for the size of the text
  8. Click OK to close the dialogue box
  9. The text is formatted

That's quite a chore, and will soon get very boring if we have to do it over and over again! The macro we write will do all that for us. See how to do it by clicking below.

Learn how to create a Macro -->

 
Computer Tutorials List