Examining Styles and Macros in a Template

Written by Allen Wyatt (last updated July 6, 2019)
This tip applies to Word 2007, 2010, 2013, 2016, 2019, and Word in Microsoft 365


1

Templates are designed to contain a collection of styles, macros, and other customizations that can be used to help consistently develop a document or series of documents. If you receive a template from someone else (or open one that you created years ago), you may wonder if there is a way to display the details of the styles and macros contained within that template.

There is no built-in way to do this, unfortunately. (It would be very helpful if there were.) Word allows you to see which styles are in a template or, for that matter, in a document relatively easily. All you need to do is load the template and use the Organizer to look at the styles it contains. If you prefer, you could use a macro to list in a new document all the styles in the current one. There are many ways to approach such a task; the following is one written by Jessica Weissman:

Sub describeAllStylesWeCareAbout()
'  by Jessica Weissman

    Dim docActive As Document
    Dim docNew As Document
    Dim styleLoop As Style

    Set docActive = ActiveDocument
    Set docNew = Documents.Add
    For Each styleLoop In docActive.Styles
        If styleLoop.Type < 3 Then
        ' show only character and paragraph styles, not list or table styles
            With docNew.Range
                .InsertAfter Text:=styleLoop.NameLocal & Chr(9) _
                  & styleLoop.Description
                .InsertParagraphAfter
                .InsertParagraphAfter
            End With
        End If
    Next styleLoop
End Sub

The problem with either approach (Organizer or special macro) is that they don't list any modifications to built-in styles that are often so important to design a template effectively. For instance, if the Normal style on a system is normally set to 10-point Arial and that has been changed to 12-point Times New Roman in the template, there is no way with the above solutions to tell that this change has been made; you only know that the template uses the Normal style. (Duh! All templates contain the Normal style.)

When it comes to macros, you need to load the template and simply go look in the Visual Basic Editor. There is where you'll find the macros and be able to try to figure out what they do. (Make sure you use the Project window to look for VBA projects specifically associated with the template.)

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

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

Restoring a Keyboard Shortcut

Word uses keyboard shortcuts for all sorts of tasks. Sometimes you may create a shortcut that messes up one of the other ...

Discover More

Showing Text when a Cell is Empty

Wouldn't it be great if you could have Excel display some text in a cell only when that cell is empty? Unfortuantely, ...

Discover More

Differing Column Widths when Pasting

When you move information from one table to another, you may be faced with the problem of making that information fit ...

Discover More

The First and Last Word on Word! Bestselling For Dummies author Dan Gookin puts his usual fun and friendly candor back to work to show you how to navigate Word 2013. Spend more time working and less time trying to figure it all out! Check out Word 2013 For Dummies today!

More WordTips (ribbon)

Determining the Template Attached to a Document

If you've opened a document in Word, that document has a template attached to it. This tip looks at what those templates ...

Discover More

Creating a Document Based on a Template

Double-click a Word template file in Windows, and Word should create a brand new document based on that template. If this ...

Discover More

Where Are Templates Stored?

Need to know where templates are located in Word 2007? The locations may be the same as in earlier versions of the ...

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 2 + 2?

2019-07-06 12:28:50

Anne Denniston

All versions of Word can print a useful list of the styles used in your document with a description of what is in them, as shown in the figure below. On the left, the Print Option is set to Styles, and on the right is the resultant list. (see Figure 1 below)
I printed to PDF with 'PDFill' (a versatile free program) and then opened the PDF with Word, which converted it into an editable Word document. It looked good because it retained bolding and converted tabs to spaces.
When I printed with 'Microsoft Print to PDF' and then opened the PDF with Word, the editable Word document did not retain bolding but also converted tabs to spaces.

Figure 1. How to obtain a descriptive list of Normal styles


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.