Style Macros

The August 18 issue of Editorium Update featured a macro to delete styles that exist in a Word document but are not used in that document. While I was writing that macro, I also wrote a couple of others that I thought you might find useful.

The first macro, ListCustomStyles, lists (at the end of the document) any custom styles in that document. If you need to know what weird styles your client is using, this macro will tell you what they are.

The second macro, ListStylesInUse, lists (at the end of the document) any style being used in that document.

If you don’t know how to use macros like these, you can learn how here:

And now, here are the macros. Enjoy!

Sub ListCustomStyles()
For Each sty In ActiveDocument.Styles
If sty.BuiltIn = False Then
Selection.EndKey Unit:=wdStory
Selection.InsertAfter Text:=sty.NameLocal
End If
Next sty
End Sub
Sub ListStylesInUse()
For Each sty In ActiveDocument.Styles
If sty.InUse = True Then
Selection.HomeKey Unit:=wdStory
Selection.Find.Style = ActiveDocument.Styles(sty)
With Selection.Find
.Text = ""
.Replacement.Text = ""
.Forward = True
.Wrap = wdFindStop
.Format = True
.MatchCase = False
.MatchWholeWord = False
.MatchWildcards = False
.MatchSoundsLike = False
.MatchAllWordForms = False
End With
If Selection.Find.Found = True Then
Selection.EndKey Unit:=wdStory
Selection.InsertAfter Text:=sty.NameLocal
End If
End If
Next sty
End Sub



In the August 11 issue, Francelia Sevin wrote:

“On my Mac in Word 2001, toggling the track changes on/off doesn’t work. I still cannot copy and paste text and include the tracked changes. I have upgraded with the latest patches for 2001 and that hasn’t made any difference.”

I asked for help with this, and Hilary Powers responded:

That sounds like the PC Word 97 tracking-copy bug, alive and well in Mac Word 2001. If so, the PC workaround–bookmarking the material and inserting it in its new spot (with tracked changes turned off in the receiving document)–should work just fine. To move something in the same document, save the bookmarked file under a different name, then reopen the active file and turn off tracking, insert the bookmarked passage from the copy, and delete it from its original location. Then turn the tracking on again, and you’re back in business.


Karen Bojda responded to the same question:

Well, there’s the workaround I learned about on CE-L, but for some reason I think you already know about this one 😉

“This is a known ‘issue’ (bug) in Word 97/98. It’s been fixed in Word 2000 and higher. A workaround is to insert the text (Insert > File) into the new document rather than paste it. If you don’t want to insert the whole doc, you can bookmark just the part you need and then enter the name of the bookmark into the ‘Range’ box of the Insert dialog.”

I can confirm that this works in Word 98 on the Mac. You have to save a copy of the file under a different name, since Word won’t let you insert a file (or even a bookmarked part of a file) into itself. It might be a cumbersome workaround, but I’ve used it and been grateful to know about it.


A more detailed explanation of how to do this is provided in the March 24 issue of Editorium Update:

Many thanks to Hilary and Karen.



Copernic Desktop Search is a powerful (and free!) file indexing and search engine for Windows computers. The website says:

“Easily search your entire hard drive in less than a second to pinpoint the right file, e-mail, music or pictures.

“CDS brings the power of a sophisticated, yet easy-to-use search engine right to your PC and allows you instantly to search files, e-mails, and email attachments stored anywhere on your PC hard drive. It executes sub-second searching of Microsoft Word, Excel, and PowerPoint files, Acrobat PDFs, and all popular music, picture and video formats. CDS also searches your browser history, favorites, and contacts.”

Thanks to Keith Soltys for bringing this program to my attention. If you’re a Mac user and know of a similar program for Macintosh, please let me know.

This entry was posted in Editing. Bookmark the permalink. Post a comment or leave a trackback: Trackback URL.

Post a Comment

You must be logged in to post a comment.

  • The Fine Print

    Thanks for reading Editorium Update (ISSN 1534-1283), published by:


    Articles © on date of publication by the Editorium. All rights reserved. Editorium Update and Editorium are trademarks of the Editorium.

    You may forward copies of Editorium Update to others (but not charge for it) and print or store it for your personal use. Any other broadcast, publication, retransmission, copying, or storage, without written permission from the Editorium, is strictly prohibited. If you’re interested in reprinting one of our articles, please send an email message to

    Editorium Update is provided for informational purposes only and without a warranty of any kind, either express or implied, including but not limited to implied warranties of merchantability, fitness for a particular purpose, and freedom from infringement. The user (you) assumes the entire risk as to the accuracy and use of this document.

    The Editorium is not affiliated with Microsoft Corporation or any other entity.

    We do not sell, rent, or give our subscriber list to anyone.