Free computer Tutorials

home

 

Assign your Word Macro to a Key on your Keyboard

We're going to create a new Macro for this lesson. The Macro will insert a textbox onto the page for us. It will do this when we press certain keys on the keyboard.

To create our new macros and then assign it to the keyboard, do the following. (Actually, you do it the other way round: assign the key first, then record the macro!)

  • Position your cursor at the start of a new blank line
  • Click on Tools from the menu bar
  • From the drop down menu, click on Macro
  • From the sub menu, select Record New Macro
  • The Record Macro dialogue box appears
  • Type in a name for the new macro. Called it InsertTextBox.
  • To assign the macro to the keyboard, click the keyboard icon, as in the image below:

Click on the Keyboard icon

When you click on the Keyboard icon, a new dialogue box appears. This one:

The Customize Keyboard dialogue box

The part we're interested in is the text box underneath Press new shortcut key, right at the bottom.

  • Click your cursor inside the text box
  • Press the F2 one key on your keyboard
  • Your textbox will say this underneath it:

The F2 key is currently assigned to another Macro

As you can see, it says Currently assigned to: MoveText. What it's telling you is that they key F2 already has a shortcut assigned to it. So we can't use F2 for our macro.

  • Click inside the textbox again, and delete F2 by hitting the backspace key on your keyboard
  • Hold down the Ctrl key on your keyboard
  • Keep the Ctrl key held down and press the number 1 on your key board. (NOT the number 1 above the QWERTY keys, but the number 1 on the right hand side of your keyboard. Make sure the Num Lock is on.)
  • Your "Press new shortcut key" textbox will now look like this one below:

The new shorcut key

As you can see, it now says Currently assigned to: Unassigned. (If yours does not say Unassigned, then try a different number. ) That means no other shortcut is using these key combinations. So we can go ahead and use them for our macros.

To use them for your macro, click the "Assign" button:

Click the Assign button to use your new shortcut keys

  • Click the Close button
  • You will be returned to your document
  • The recorder will be displayed again, waiting for you to record your new macro.

To record your new macro, do the following:

  • With the recorder displayed, click on Insert from the menu bar
  • From the drop down menu, click Text Box
  • Move your mouse pointer down to your white page (the pointer will have the little cassette tape under it)
  • Hold down your left mouse button
  • Keep the left mouse button held down and drag your mouse outwards until you have a decent-sized text box
  • Let go of your mouse button. Then click the Stop button on the Recorder

Your macro is now recorded. Time to test it out to see if it works. To test out your new macro, do the following.

  • Get rid of the text box on the page by clicking Edit from the menu bar (make sure your text box has the white squares around it. If not, click on the text box with your left mouse button)
  • From the drop down Edit menu, click on Cut
  • The text box is deleted from your page
  • Hold down the Ctrl Key on your keyboard
  • Keep the Ctrl Key held down
  • Press the number 1 on your keyboard, the same number 1 that you used when recording your macro
  • A text box will appear on your page

If you didn't get a text box on the page, then something went wrong. So no choice but to try again! You can record over the InsertTextBox macros just like you did before, if a mistake was made.

So there you have it: a handy shortcut every time you need a text box. All you have to do is press Ctrl and then the number 1 key. A text box will pop up on the page. It will pop up in exactly the same position each time you use the shortcut. But text boxes are easy to drag around and position elsewhere.

We'll now see how to assign a macro to the toolbar.

Learn how to assign a Macro to the Word Toolbar -->

<--Back to the Word Contents Page

View all our Home Study Computer Courses

 
Computer Tutorials List