Written by Allen Wyatt (last updated April 11, 2026)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, 2021, 2024, and Word in Microsoft 365
Jasmin needs a way to somehow flag sentences that begin with a set of undesirable words, such as conjunctions.
The easiest way to accomplish this task is to use a macro. Conceptually, the macro needs to step through each sentence in a document, look at the first word in the sentence, and flag the word if it is undesired. The following macro will do just that:
Sub HighlightBadFirstWords()
Const BadWordList = " And Or But Hopefully "
Dim s As Range
For Each s In ActiveDocument.Content.Sentences
If InStr(1, BadWordList, " " & _
Trim(s.Words.First.Text & " "), vbTextCompare) Then
s.Words.First.HighlightColorIndex = wdYellow
End If
Next s
End Sub
The key to this macro is putting together the undesirable words in the BadWordList constant. Notice that each word is separated by a space and there is a space at the beginning and end of the words. This spacing is important. It is also important to make sure that none of the words includes any punctuation marks.
The reason for this is rather simple. The macro uses the Words collection for each sentence in the document. This collection treats punctuation as a word. Thus, if a sentence began with "But," (with the comma), then that is two words—"But" and ",".
You should also understand that the macro is case insensitive. So, if a sentence begins with "AND," that will be marked, even though the BadWordList constant contains "And". If you want to make the macro pay attention to case, then change vbTextCompare to vbBinaryCompare.
All of that said, Jasmin may want to remember that there is no grammatical rule that indicates it is improper for a sentence to start with a conjunction. Check your favorite style guide, and you will find that this is the case. (Mine tends to be the Chicago Manual of Style. In the 17th edition, see 5.203; in the 18th edition see 5.209.) Even with no disallowing rule in place, however, you may find it helpful to mark such words to make sure that their sentence-beginning use is warranted.
Note:
WordTips is your source for cost-effective Microsoft Word training. (Microsoft Word is the most popular word processing software in the world.) This tip (13973) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, 2021, 2024, and Word in Microsoft 365.
Do More in Less Time! An easy-to-understand guide to the more advanced features available in the Microsoft 365 version of Word. Enhance the quality of your documents and boost productivity in any field with this in-depth resource. Complete your Word-related tasks more efficiently as you unlock lesser-known tools and learn to quickly access the features you need. Check out Microsoft 365 Word For Professionals For Dummies today!
When you paste information into Word from the internet, you may get more than just the plain text you hoped for. This tip ...
Discover MoreIf you have a need for special characters (particularly in technical documents), Word provides a couple of ways you can ...
Discover MoreOne of the most overlooked shortcut keys in Word has to be the extend key. Yet, learning how to use this simple key can ...
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 © 2026 Sharon Parq Associates, Inc.
Comments