Making Highlighting Disappear when Typing

by Allen Wyatt
(last updated October 20, 2018)

2

When James applies a highlight color (such as yellow) to a word, the background around that word turns yellow. When he then selects that highlighted word and types a new word over it, the new word appears, but the yellow highlighting remains. To get rid of the yellow highlighting, he must select the word again and "unhighlight" it. Since James has to do this hundreds of times a day, it gets old. He wonders if there is a way to make the highlighting disappear when selecting and typing over a word.

The short answer is that there is no easy way to do this. The reason, apparently, has to do with the your text and the highlighting being on different layers of the document. When you select some highlighted text and start typing, then you are affecting only the layer on which your text resides; the layer on which the highlighting resides is not affected.

There are a few workarounds you can try out, though. One is to simply press the Delete key after you select your text and before you start typing. This does affect both layers, and you can immediately begin typing without the lingering highlight.

A second approach is to use Word's shortcut key that controls highlighting: Ctrl+Alt+H. This shortcut toggles the highlight on whatever text is selected, so it is a quick way to turn the highlight on and off.

A third approach is great if you are using styles and the highlighted text doesn't have any explicit formatting (besides highlighting) attached to it. All you need to do after selecting the text is press Ctrl+Spacebar, which removes any explicit formatting, including the highlighting.

A fourth approach is to use a macro to remove the highlighting. The following will remove the highlighting from whatever text you have selected:

Sub RemoveHighlight1()
    Options.DefaultHighlightColorIndex = wdNoHighlight
    Selection.Range.HighlightColorIndex = wdNoHighlight
End Sub

You can assign this macro to a shortcut key, which will make it easy to apply as you are typing along. In many respects, it isn't much different than the second approaching I suggesting, using the Ctrl+Alt+H shortcut. You could, though, modify the macro just a bit to make it even more valuable:

Sub RemoveHighlight2()
    Selection.Words(1).Select
    Options.DefaultHighlightColorIndex = wdNoHighlight
    Selection.Range.HighlightColorIndex = wdNoHighlight
End Sub

Assuming you want to remove the highlighting from a word, all you need to do is position the insertion point within the word (no need to select the entire thing), run the macro, and then start typing. The macro selects the word and turns off highlighting, and since you start typing right after the macro is complete, you end up replacing whatever word you affected.

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 (13574) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, and Word in Office 365.

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

Using a Single-Column Heading in a Multi-Column Layout

Want different numbers of columns all on the same page? Word makes it easy to use, for instance, a heading that uses a ...

Discover More

Workbook not Saving

Having trouble saving a workbook? It could have to do with the age, size, and complexity of that workbook. This tip ...

Discover More

Microsoft Word VBA Guidebook

Creating Word macros allows you to extend your productivity with Word. Visual Basic for Applications (VBA) is the ...

Discover More

Comprehensive VBA Guide Visual Basic for Applications (VBA) is the language used for writing macros in all Office programs. This complete guide shows both professionals and novices how to master VBA in order to customize the entire Office suite for their needs. Check out Mastering VBA for Office 2010 today!

More WordTips (ribbon)

Using Manual Line Breaks with Justified Paragraphs

If you use justified paragraphs, you know that if you press Shift+Enter, it can lead to some odd spacing between words ...

Discover More

Quickly Deleting Words

Tired of pressing the Delete or Backspace key for every character you want to delete? Here's a way you can make your ...

Discover More

Differences between Deleting, Clearing, and Cutting

When getting rid of text from your document, Word allows you to delete, clear, or cut. Here are the differences between ...

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}] 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 6 - 1?

2018-11-02 15:59:58

Lisa

Ctrl + spacebar doesn't work for me either. The highlighting remained.


2018-10-22 10:04:31

Fred Seelig

Allen, the first option only works if you delete to a point that doesn't have highlighting. (If you delete with highlighting continuing after what you deleted, it doesn't work.) I'm using Word 2016/365, but this has always been my experience, going back to Word 6.0 -- whatever styling was in the location that you just deleted remains active for whatever you type next. It's easiest to see this by turning on the Show/Hide function and experimenting.

Ctrl+Alt+H works fine.

Ctrl+Spacebar doesn't work for me. It changes other style attributes, such as font type and point size, but the highlighting remains.

I haven't tried the macro.


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.

Newest Tips
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.