Written by Allen Wyatt (last updated September 11, 2024)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, and Word in Microsoft 365
Tricia has a lot of documents that she works with for her employment. These documents have many words that are underlined and many others that have "strikethrough" formatting. Tricia needs a way, at any given time, to know how many words in the document are underlined and how many are "struck through."
There are a couple of non-macro approaches you can use to get the counts you need, both of which are quick and easy. Here's one that is rather esoteric, but works great:
There is one caveat to this approach: When you use the Select Text with Similar Formatting, Word is pretty discriminating in what it selects. For instance, if you have a word that is bold and underlined, but you select a word that is non-bold and underlined in step 4, then the bold and underlined word is not selected after step 6. The reason is that Word considers the bolding enough of a "disqualifier" that the formatting is no longer similar. Still, if your words use simple underlining or simple strikethrough, then these steps will work quickly and easily. (Plus, you get the benefit of having the words themselves in a different document where you can further analyze them.)
Another approach is to use the Find and Replace feature of Word to derive the count. Follow these steps, for example, if you want to find the count of words that are struck through:
Figure 1. The Find tab of the Find and Replace dialog box.
Figure 2. The Find Font dialog box.
Word does a good job of highlighting individual words if you use this approach. Thus, if you have the text "John followed the path for about a mile", these steps will see this as 8 separate words and reflect that in the count. The reason is because of the pattern matching you specified in step 9. It indicates that the match must be at the beginning and end of a word.
The search pattern you specify in step 9 will match only words that contain uppercase or lowercase letters. It won't match words that contain (beginning, middle, or end) any numbers. Thus, the word "CH2M" (an actual portion of a company name) would not be considered a match. If you believe you may have digits in some of your words, then use the search pattern <[A-Z,a-z,0-9]@> in step 9, instead.
If you decide to use the Find and Replace approach, you'll need to repeat the steps for each type of formatting you want to find. Actually, if you are going to get your counts all at the same time, you can simply repeat steps 5 through 10 over and over again, selecting a different formatting option each time in step 6. (Word actually has two strikethrough settings and 16 or so different types of underlining.)
While the two methods of getting counts discussed in this tip focus on counting underlined or struck-through words, the same two techniques can be used to search for any type or mix of formatting you desire; they are very versatile.
WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (13039) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, and Word in Microsoft 365.
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!
Do you want to quickly search for any footnote or endnote marks in your document? Word makes it easy using the standard ...
Discover MoreHidden text is a great boon if you want to make sure something doesn't show up on the screen or on a printout. If you ...
Discover MoreWhen you receive documents created by others, it is not unusual that you'll want to edit what they've written. For ...
Discover MoreFREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
There are currently no comments for this tip. (Be the first to leave your comment—just use the simple form above!)
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.
Visit the WordTips channel on YouTube
FREE SERVICE: Get tips like this every week in WordTips, a free productivity newsletter. Enter your address and click "Subscribe."
Copyright © 2024 Sharon Parq Associates, Inc.
Comments