Improve Your Writing with Macros


By C.K. MacLeod


There is a lot you can do to improve your writing. Some improvement tasks will take you hours to accomplish, but some of them can be quick and easy with the help of macros.

What are macros?

Macros are tiny programs that can handle repetitive and finicky fix-up tasks that would otherwise take you loads of time. Word processing programs like Microsoft Word have the ability to run macros.

Where do you find macros?

You can write your own macros, but it's often easiest to find and tweak existing ones. Paul Beverley's free book, Macros for Writers and Editors contains over 400 macros for writing and editing tasks.

At the beginning of his book, Beverly offers detailed instructions for understanding and using macros in various versions of Word. He also explains what each macro does. You can copy the macro scripts from the file that accompanies the book of instructions and add them to Microsoft Word.

Free macros for writers

I combed through Paul Beverley's free macro book and selected a few macros that writers can use to improve common writing bugbears:

LongSentenceHighlighter—highlights sentences that are too long
CountPhrase—select a phrase in the text and Countphrase will count the number of occurrences—this can tell you if a phrase has been overused
HighlightSame—selected a word or phrase, and HighlightSame will highlight all instances of it—also great for identifying those overused words and phrases

Because two of the macros above highlight text, once you've addressed those highlights, you'll want to remove them from your file in one fell swoop. Paul Beverley's HighlightAllOff does the trick. You can use his UnHighlight to remove highlights selectively.

Karen Woodward also shares two macros that may be useful to writers:

highlight_ly—highlights adverbs ending in "ly"; writing with strong nouns and verbs is always preferable
highlight_targets—highlights words that can clutter your writing, like the weak words "very" and "that"; you can customize the macro by adding other lists of words, too.

These two macros are my current favourites:

NeedlessWords—removes words that clutter your writing (my versionof Karen Woodward's highlight_targets)

TellingWords—highlights potential instances of telling, so you can change them to showing

The macros above allow you to consider why you've used certain words in your writing. Addressing needless words and telling words can help you tighten your prose and keep your reader engaged in your story.

And finally, author and editor Ryan Macklin has designed a macro to detect the passive voice in your writing. While a bit of passive voice is quite alright, too much passive voice can make your text more challenging to read.

Macros can help you to see and catch potential problems that you'd otherwise miss in your writing.

Do you have a favourite writing macro?

Image by Matt Scott

9 thoughts on “Improve Your Writing with Macros”

  1. Corina,
    I tried using Paul's Longsentencehighlighter and I saw it identify the sentence as the program ran but when it was done, no sentences were highlighted.

    Any idea what's up?
    The macro codes have highlighted text. Should I take out the highlight around the text? I can show you the actual code if you want. My email is

    Thanks so much for the help and easy steps with macro's. I really like the idea of using them but I don't know code at all so can only follow steps others give me.

    Thanks for your help!

    1. Christine,
      Glad you liked the macro course! I've only just begun to learn to read and manipulate macro code myself. Jack Lyon's Macro Cookbook has been most helpful in that regard. You don't need to know how to read macros to use them, though. It does help for tweaking, though.

      If you have no highlighted sentences after you've run the macro, my guess is that your sentences didn't meet the criteria for long sentences in Paul Beverley's LongSentenceHighlighter macro (good, right?). A quick peek at the macro code tells me that sentences are measured in this way:

      mediumLength = 80
      megaLength = 120

      That's 80 and 120 words, I believe. Medium-length sentences are highlighted in yellow and mega length sentences in red. I'd suggest a little experimentation. You can change those numbers in the macro in Word's VBA (CTRL + F11—then look to where you stored that macro—in Normal?) and run the macros on a junk document to see what happens. In general, from a plain-language perspective, sentences longer than 20 words are considered long. So you can pop 20 in place of 80 to see what happens. What's nice is that this macro is flexible. You can decide what qualifies as a long sentence.

      What do you think?

      After you've highlighted long sentences, you can go through the document to make them shorter. After you've done that, you can remove all the highlighting with a macro (Paul Beverley has one called UnHighlightAll) or you can use Word's unhighlight button in the Home tab, Font area.


      1. Actually, there are long sentences, and as the program ran, I saw the macro find them and highlight them in gray briefly (it runs fast, as you probably know) but when it was done, there were no highlights.

        I tried the macro you had on your post for needless words, and that worked fine. The obvious difference I noticed between that macro and the long sentence one was highlighted text. Here is an example of what I mean:

        (This whole first section - from Sub to Alt-H - is highlighted in gray - it didn't copy to this reply)
        Sub HighlightOffWord()
        ' Version 28.01.12
        ' Remove highlight from all occurrences of this word
        ' Alt-H

        doNotes = True

        ' Select current word

        ('selected current word is also in gray)

        1. Hmm. The code above suggests that the macro removes highlighting. Do you see the text with the apostrophe in front of it? Anything with an apostrophe in front of it is an explanation, and is not part of the macro code (Word's VBA ignores it). Is it possible that you have the wrong macro? (The macro is titled HighlightOffWord.) The HighlightLongSentence macro will apply red and yellow highlighting to long sentences.

          Paul Beverley just updated his macro book, so you could see if there are amendments to the HighlightLongSentence macro in the changes log at the end of the new book. I would try copying the macro again, from the new book (the macros are in a separate file), and then pasting the new one into Word's VBA (delete the old one first). If you're still running into trouble, Paul Beverley encourages users to let him know if there's a problem with a macro.

          Hope this helps!

    2. The long sentence highlighter simply doesn't work. The initial time I ran it, it worked correctly for a while—highlighting medium length sentences as yellow and long sentences as red—but then, inexplicably, midway through the document, it switched colors!

      I re-pasted the code and examined it to make sure all the indentation and anything else that might affect it was in order, and then ran it again. This time, it highlighted medium sentences only, sometimes in yellow, sometimes in red. Long ones it didn't seem to touch at all.

      The bottom line is, the macro doesn't work. There's a bug in the code. On that basis, I'd be suspicious about counting on any of the others in this

      1. Oh, no! How frustrating for you, Christine. Paul Beverley is super approachable, so if you've found a bug in the LongSentence macro, do let him know. He updates macros frequently. You can reach him through Archive Publications. In the meantime, you could try the Hemingway Editor. It also checks for long sentences.

  2. Hi Corina,

    Love your macro course! Thank you so much for sharing your knowledge.

    What I'd like to know is whether it's possible to run two macros or more consecutively (for example, run NeedlessWords and TellingWords one after the other so both cases are highlighted throughout the MS), or whether only one can be run at a time. In other words, you'd check and fix all the highlighted instances the first macro found, then run the next macro and check and fix all the highlighted instances that second one found, and so on.

    It seems if I did the former, there'd be a lot of highlights for different types of problems in the manuscript, and it would get confusing and cluttered.

    I hope I'm not confusing you. It's rather hard to describe what I mean.

    1. Arlene,
      Yes. You can run macros consecutively. The macros on this site are colour-coded, so you'll be able to tell them apart in a document. You can run two or three at a time, if you like!

Leave a Reply

Your email address will not be published. Required fields are marked *