If you’re into writing, you’re probably interested in readability. To help you get a handle on sentence length, use the following Word macro to highlight long sentences.

Tools such as the Hemingway Editor are vital for any writer, especially those who create website content. After all, readability influences page rank in Google search results. In other words, if you’re concerned about SEO, you should be concerned about readability.

Yoast Readability Analysis

If you use the Yoast SEO plugin, expand the readability tab. There, you’ll see your Flesch score. If it’s yellow, say in the 50s, the plugin suggests that you use shorter sentences.

Well, you can paste your text into Hemingway. It will highlight sentences that are difficult to read. However, if you correct all the problems, Yoast might still deny you a green light.

So, the next step is to use shorter sentences. However, if you have a 2,000-word article, highlighting each sentence to do a word count can take a lot of time.

What you need is a software tool that will automatically flag long sentences. Unfortunately, most word processors and writing tools don’t have this capability.

That’s why you’ll probably have to use Microsoft Word.

What Doesn’t Work

Allen Wyatt posted a Word macro to highlight long sentences. However, it uses the “Words” property to count words.

The problem with using the “Words” property is that it counts punctuation and paragraphs as words.

In other words, the results of Wyatt’s macro are unreliable.

Don’t use Wyatt’s macro. OK?

Word Macro to Highlight Long Sentences

Microsoft has a useful knowledge base article that addresses the aforementioned problem. It’s called Word count appears inaccurate when you use the VBA “Words” property.

Essentially, rather than using the “Words” property, you have to use the “ComputeStatistics” method to get an accurate word count.

So, I went ahead and updated the macro to work with “ComputeStatistics” rather than “Words.”

Here it is:

Sub longSentences()

Dim i As Integer
Dim j As Integer

i = ActiveDocument.Sentences.Count

For j = 1 To i

Set myRange = Documents(ActiveDocument).Sentences(j)
wordCount = myRange.ComputeStatistics(Statistic:=wdStatisticWords)
If wordCount >= 20 Then ActiveDocument.Sentences(j).HighlightColorIndex = wdBrightGreen

End Sub

Just pop the above code into your MS Word and it will highlight sentences with 20 or more words. Of course, you can change the sentence length to whatever you want.

More reading

30 Ways to Get FREE Website Traffic in 30 Minutes or Less Free Website Traffic: 30 ways to Get it in 30 Minutes or Less - You need free website traffic. Don't you? Regardless of whether you're starting a new business or building your personal brand,… Continue Reading
Beware of Onavo Protect Facebook's Fake Free VPN Beware of Onavo Protect, Facebook’s fake free VPN - Tell everyone you know to avoid free VPN services. Bottom line: A free VPN isn't free. To illustrate this point, consider… Continue Reading
Marketing Process Steps Marketing Process Steps [Part 4 of Marketing Basics] - I've given you an overview of some basic concepts of marketing. Today I want to emphasize the continuous nature of… Continue Reading

NEW! Buy the e-book, “30 Ways to Get FREE Website Traffic in 30 Minutes or Less.” Our fast, secure checkout is powered by Square.