Protecting Custom Shortcut Keys

Written by Allen Wyatt (last updated October 28, 2023)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, Word in Microsoft 365, and 2021


1

Susan has created a good number of shortcut keys to various symbols, and she uses those shortcuts all the time. Every so often the shortcut keys disappear, however. This may happen whenever Microsoft updates Word on her system, but Susan don't know for sure. She wonders how she can protect her shortcut keys so they don't disappear.

When you customize the keyboard shortcuts in Word, those customizations are stored, by default, in your Normal template. If the Normal template is overwritten or deleted for any reason, then the keyboard shortcuts are deleted. (Not only that, but any macros and custom styles!)

Your Normal template has the largest chance of being overwritten when your software is updated, which is what Susan is suspecting in her case. If you work in a corporate environment, your Normal template could also be overwritten whenever your network administrator updates the template. Regardless of when it is happening, one solution to the problem is to make sure you make a backup of your Normal template. All you need to do is to get out of Word and locate the Normal template (Normal.dotm). Your Normal template will be in a folder similar to this:

C:\Users\<your username>\AppData\Roaming\Microsoft\Templates\

Once you locate the template, copy that file to a backup location, such as a flash drive. Make sure you also jot down the path for the folder in which the template is located on your system. This will allow you, once you detect that your shortcut keys have disappeared, to get out of Word, go to the same folder, and put your backup copy of the Normal template into that folder. When you restart Word, all your shortcut keys (and macros and styles) should once again be available.

This approach of making a backup of your Normal template should be done anytime you create or delete shortcut keys, macros, or styles. That way you'll always have the most recent version of your changes backed up and ready in case you need it.

Another approach is to not save shortcut keys (or the other items) in your Normal template. Instead, put them in a different template. When you look at the Customize Keyboard dialog box (used whenever you define a shortcut key), you'll notice that you can specify where the shortcut key should be saved. (See Figure 1.)

Figure 1. When defining a shortcut key, you can specify where it should be stored.

If you store your shortcuts in a different template than Normal.dotm, then they won't disappear when your software is updated or when the Normal template is deleted.

Regardless, though, of where you store your shortcut keys, you should always make a list of what your shortcut keys are so that, if worse comes to worse, you can recreate them from scratch. Or, if you prefer, you can even use a macro to recreate the shortcut keys. Here is an example of a macro that defines four shortcut keys:

Sub Set_Shortcuts()

    'insert em dash / CTRL + -
    KeyBindings.Add wdKeyCategorySymbol, Chr(151), BuildKeyCode(wdKeyControl, wdKeyHyphen)

    'run the New Comment command / ALT + m
    KeyBindings.Add wdKeyCategoryCommand, "InsertAnnotation", BuildKeyCode(wdKeyAlt, wdKeyM)

    'run ToggleBookmarkDisplay macro / ALT + SHIFT + s
    KeyBindings.Add wdKeyCategoryMacro, "ToggleBookmarkDisplay", BuildKeyCode(wdKeyAlt, wdKeyShift, wdKeyS)

    'apply the Emphasis style / ALT + e
    KeyBindings.Add wdKeyCategoryStyle, "Emphasis", BuildKeyCode(wdKeyAlt, wdKeyE)
End Sub

Note that the macro relies on the use of the KeyBindings method, which is used to "bind" an action to a keystroke. In other words, it is used to define shortcut keys. You can find information about the KeyBindings.Add method on this Microsoft site page:

https://learn.microsoft.com/en-us/office/vba/api/word.keybindings.add

Even though it may take a bit of effort to figure out and put the macro together (especially if you have a lot of shortcuts), there are some benefits to doing so. First, the macro code can be taken to any computer and run, on that other computer, in order to install the shortcuts. Also, if your shortcuts are messed up by you or by Word, they can be quickly reset by running the macro.

Note:

If you would like to know how to use the macros described on this page (or on any other page on the WordTips sites), I've prepared a special page that includes helpful information. Click here to open that special page in a new browser tab.

WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (791) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, Word in Microsoft 365, and 2021.

Author Bio

Allen Wyatt

With more than 50 non-fiction books and numerous magazine articles to his credit, Allen Wyatt is an internationally recognized author. He is president of Sharon Parq Associates, a computer and publishing services company. ...

MORE FROM ALLEN

Removing Shading from Many Paragraphs

Need to format a bunch of paragraphs within your document? Word provides some very easy ways to apply the same formatting ...

Discover More

Limits on Path Length in Word

When you organize your hard drive, it is easy to go hog-wild with folders and subfolders. You need to know that how you ...

Discover More

Stopping Enter from being Pressed In a Form

If you create a form using Word, chances are good that you don't want a user to mess up the layout of the form by ...

Discover More

Create Custom Apps with VBA! Discover how to extend the capabilities of Office 2013 (Word, Excel, PowerPoint, Outlook, and Access) with VBA programming, using it for writing macros, automating Office applications, and creating custom applications. Check out Mastering VBA for Office 2013 today!

More WordTips (ribbon)

Keyboard Shortcuts for Zooming

For whatever reason, Microsoft has never seen fit to provide built-in keyboard shortcuts for zooming in and out. Here are ...

Discover More

Shortcut Keys Don't Work as Expected

We all come to depend on shortcut keys to perform tasks in Word. If those shortcut keys don't do what we expect, it can ...

Discover More

Restoring a Keyboard Shortcut

Word uses keyboard shortcuts for all sorts of tasks. Sometimes you may create a shortcut that messes up one of the other ...

Discover More
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

View most recent newsletter.

Comments

If you would like to add an image to your comment (not an avatar, but an image to help in making the point of your comment), include the characters [{fig}] (all 7 characters, in the sequence shown) in your comment text. You’ll be prompted to upload your image when you submit the comment. Maximum image size is 6Mpixels. Images larger than 600px wide or 1000px tall will be reduced. Up to three images may be included in a comment. All images are subject to review. Commenting privileges may be curtailed if inappropriate images are posted.

What is four less than 7?

2023-10-28 19:05:07

Susan

THANK YOU - This was very helpful!!


This Site

Got a version of Word that uses the ribbon interface (Word 2007 or later)? This site is for you! If you use an earlier version of Word, visit our WordTips site focusing on the menu interface.

Videos
Subscribe

FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."

(Your e-mail address is not shared with anyone, ever.)

View the most recent newsletter.