Changing Pronoun Gender

Written by Allen Wyatt (last updated October 31, 2020)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, and 2021


3

Robert would like to have a macro that changes the gender of pronouns in documents and wonders if, perhaps, there is anything suggested to make such changes.

If you are looking for a macro to change the gender of all pronouns in a document, that is relatively straightforward—all you need is one that will do universal search and replace operations for male pronouns and change them to female pronouns, or vice-versa.

If, however, you are looking for a macro that will alternate pronouns—first usage is male, second is female, etc.—such as is often done in non-fiction writing, that is a different story. That is best left to a skilled editor to make the judgment calls on which changes to make and how far to extend those changes.

So, assuming you want to go the universal route, the best approach is to use a macro that utilizes wildcard searching using pairs of pronouns (one male pronoun with a corresponding female pronoun) to specify the changes to be made. The following example uses such an approach to change he, him, his, and himself to the female forms (she, her, hers, herself) or vice versa.

Sub MaleToFemale()
    GenderChange (True)
End Sub
Sub FemaleToMale()
    GenderChange (False)
End Sub
Sub GenderChange(isMale As Boolean)
    Dim aRange As Range
    Dim fTest As Boolean
    Dim j As Long
    Dim k As Long
    Dim male
    Dim female
    male = Array("he", "He", "HE", "him", "Him", "HIM", "his", _
                 "His", "HIS", "himself", "Himself", "HIMSELF")
    female = Array("she", "She", "SHE", "her", "Her", "HER", "hers", _
                   "Hers", "HERS", "herself", "Herself", "HERSELF")

    ActiveDocument.TrackRevisions = True
    Set aRange = ActiveDocument.Range
    With aRange.Find
        .ClearFormatting
        .Replacement.ClearFormatting
        .Replacement.Highlight = False
        .Forward = True
        .Format = False
        .Wrap = wdFindStop
        .Format = False
        .Highlight = False
        .MatchCase = False
        .MatchWholeWord = False
        .MatchSoundsLike = False
        .MatchAllWordForms = False
        .MatchPrefix = False
        .MatchWildcards = True

        j = UBound(male)
        For k = 0 To j
            If isMale Then
                .Text = "<" & male(k) & ">"
                .Replacement.Text = female(k)
            Else
                .Text = "<" & female(k) & ">"
                .Replacement.Text = male(k)
            End If
            fTest = aRange.Find.Execute(Replace:=wdReplaceAll)
        Next k
    End With
    ActiveDocument.TrackRevisions = False
End Sub

Note that there are three macros in the listing. You should use the MaleToFemale macro to change from male pronouns to female pronouns and the FemaleToMale macro to change the other direction. The pronoun pairs themselves are in the GenderChange macro, in the male and female arrays. Note that each pronoun is included in the array three times using different combinations of upper- and lowercase characters. This is because the wildcard search is case sensitive, so the different searches for each case instance is necessary.

Note that the macro also turns on Track Changes before it makes any changes. That way every change made by the macro is noted in the document and you can then use the regular Track Changes resolution process to evaluate each change made. This is done because the English language is terribly imprecise and there is ambiguity in the usage of some words that we generally consider pronouns. For instance, the words "his" and "hers" can be used as either possessive personal pronouns or as possessive adjectives. It is only possible to distinguish the proper usage when looking at them in context, which is something the macro obviously doesn't do. Bottom line—read after changing so you can make sure your document still makes sense.

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 (12896) applies to Microsoft Word 2007, 2010, 2013, 2016, 2019, and 2021.

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

Taking Pictures

Have you ever wanted to take a "picture" of a part of a worksheet and put it in another section? This tip explains how to ...

Discover More

Selecting Different Trays in a Mail Merge

When you create a mail-merged document, you might want some pages of the document printed on paper from one printer tray ...

Discover More

Table Borders Won't Print

Print a table and you may be surprised if it has no borders. That could be because you actually have the borders turned ...

Discover More

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!

More WordTips (ribbon)

Determining the Week of the Year

If you are working with dates in a macro, you may need to determine which week of the year a date falls within. This can ...

Discover More

Moving the Insertion Point in a Macro

One of the common things done in macros is to somehow "process" documents, which often means moving the insertion point ...

Discover More

Changing a Macro Description

Part of documenting macros is to provide a good, succinct description of what they do. Changing the description of an ...

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}] (all 7 characters, in the sequence shown) 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 seven more than 2?

2022-10-28 09:33:32

cam

Thank you for this but what about changing pronouns to you, your, yourself?


2021-11-01 12:41:41

Jason

What about changing the pronouns (either male or female) to gender neutral (e.g., they/them)?


2020-10-31 14:02:06

David Cohen

I know that Allen can devise a macro for nearly every issue. An old-school way to deal this would be to find and replace each pronoun with exactly the same word but in a red (for example) font. You can then easily cruise through the document quickly, spot issues, and make changes. When you're done, highlight the entire document and make all font black.


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.

Videos
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.