Results 1 to 9 of 9
  • Thread Tools
  1. Star Lounger
    Join Date
    Feb 2004
    Location
    Houston, Texas, USA
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Style Identification (2000/SR1)

    At one time, I downloaded a macro template that, among other things, could create a table with the following information for every style used in a document:

    Style Type Based On NextParagraph Auto-Update Description

    I need to use it again but can't locate it on my computer. Has anyone seen a similar macro?

    Thanks,
    Caroline

  2. Subscribe to our Windows Secrets Newsletter - It's Free!

    Get our unique weekly Newsletter with tips and techniques, how to's and critical updates on Windows 7, Windows 8, Windows XP, Firefox, Internet Explorer, Google, etc. Join our 480,000 subscribers!

    Excel 2013: The Missing Manual

    + Get this BONUS — free!

    Get the most of Excel! Learn about new features, basics of creating a new spreadsheet and using the infamous Ribbon in the first chapter of Excel 2013: The Missing Manual - Subscribe and download Chapter 1 for free!

  3. 5 Star Lounger
    Join Date
    May 2001
    Location
    Stuttgart, Baden-W, Germany
    Posts
    931
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Style Identification (2000/SR1)

    Hi Caroline,

    It isn't too hard to write... which I did since having such a macro in the "toolbox" sounded like a good idea.

    It's not as useful as I thought, since the macro below lists all the built-in styles, too.
    To restrict the list to styles that are in use, the .InUse property isn't too helpful... you would probably need to search the document if the style is *really* used.
    <pre>Dim styleLoop As style
    Dim strOutput As String
    strOutput = strOutput & "Name" & vbTab
    strOutput = strOutput & "Type" & vbTab
    strOutput = strOutput & "Base style" & vbTab
    strOutput = strOutput & "Next paragraph style" & vbTab
    strOutput = strOutput & "Automatically update" & vbTab
    strOutput = strOutput & "Description" & vbCr
    For Each styleLoop In ActiveDocument.Styles
    strOutput = strOutput & styleLoop.NameLocal & vbTab
    Select Case styleLoop.Type
    Case wdStyleTypeParagraph
    strOutput = strOutput & "Paragraph" & vbTab
    Case wdStyleTypeCharacter
    strOutput = strOutput & "Character" & vbTab
    Case wdStyleTypeList
    strOutput = strOutput & "List" & vbTab
    Case wdStyleTypeTable
    strOutput = strOutput & "Table" & vbTab
    Case Else
    strOutput = strOutput & styleLoop.Type & vbTab
    End Select
    strOutput = strOutput & styleLoop.baseStyle & vbTab
    strOutput = strOutput & styleLoop.NextParagraphStyle & vbTab
    Select Case styleLoop.Type
    Case wdStyleTypeParagraph
    strOutput = strOutput & styleLoop.AutomaticallyUpdate & vbTab
    Case Else
    strOutput = strOutput & "--" & vbTab
    End Select
    strOutput = strOutput & styleLoop.Description & vbCr
    Next styleLoop
    Selection.EndKey Unit:=wdStory
    Selection.ExtendMode = True
    Selection.InsertAfter strOutput
    Selection.ExtendMode = False
    Selection.ConvertToTable Separator:=wdSeparateByTabs
    </pre>

    <img src=/S/cheers.gif border=0 alt=cheers width=30 height=16> Klaus

  4. 5 Star Lounger
    Join Date
    May 2001
    Location
    Stuttgart, Baden-W, Germany
    Posts
    931
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Style Identification (2000/SR1)

    BTW, you can print most of the information directly from "File > Print... > Print what: Styles". Perhaps this is what you remembered?

    <img src=/S/cheers.gif border=0 alt=cheers width=30 height=16> Klaus

  5. Star Lounger
    Join Date
    Feb 2004
    Location
    Houston, Texas, USA
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Style Identification (2000/SR1)

    Thanks, Klaus! Actually I remembered last night that the style identification was part of a larger reporting macro. You could print the entire report on a document or you could select portions of it. Options were document properties, style identification, style samples, and others that I don't remember. I'll try your macro and it may give me what I need. I used the other one to reverse engineer a document, e.g., if I needed to create documentation standards from an existing document.

    Thanks,
    Caroline

  6. Super Moderator
    Join Date
    Jan 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    3,381
    Thanks
    3
    Thanked 108 Times in 102 Posts

    Re: Style Identification (2000/SR1)

    This template sounds like the Macros8.dot template that was available with Word 97. Contained within that template is a dialog (SuperDocStatistics) which reports on styles, tables, sections, fonts etc used in the document. From memory, there were a couple of minor issues in getting this to work fully with Word 2000. Attached is a screen capture of the styles listing in case it jogs your memory. It was coded long before table styles came into being so the list isn't correct in Word XP but it used to work for me in Word 2000.

    This template has scored a few mentions in this lounge in the past (including the very recent past) so you can search for a bit more information.
    Attached Images Attached Images
    Andrew Lockton, Chrysalis Design, Melbourne Australia

  7. Star Lounger
    Join Date
    Feb 2004
    Location
    Houston, Texas, USA
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Style Identification (2000/SR1)

    That is exactly what it is - SuperDocStatistics in Macros8.dot - I wonder if it is still on the Microsoft site? I didn't have any trouble using it with Word 2000. I'll check on Microsoft but if you have it, could you send it to my personal email?

    Thanks,
    Caroline

  8. Bronze Lounger
    Join Date
    Nov 2001
    Location
    Arlington, Virginia, USA
    Posts
    1,394
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Style Identification (2000/SR1)

    I don't think this file is available from the MS web site. See this MSKB article for additional info concerning Macros8.dot template:

    WD97: How to Access Sample Macros for Word 97

    This article is mainly applicable if you still have Office 97/Word 97 installed. If not, but if you still have your Office 97 CD-ROM, you can find this file & the others mentioned in article in this folder on CD:

    E:OFFICEMACROSMACROS8.DOT

    In this case "E:" is CD-ROM drive. I had no problem copying file from my old Office 97 disk & running SuperDocStatistics in Word 2000 - see attached pic. (Note: I changed the form caption to read "Word 2000" rather than "Word 97".) The code and form modules aren't locked or anything so you can go into VB editor & see how form works & "appropriate" the code for your own projects if useful. I don't know how well it'd work in Office XP/Word 2002, but you should be able to modify code as required to fix any problems encountered in XP.

    HTH
    Attached Images Attached Images

  9. Star Lounger
    Join Date
    Feb 2004
    Location
    Houston, Texas, USA
    Posts
    95
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: Style Identification (2000/SR1)

    Actually, I found that macros8.dot is available on Microsoft. Search for Wdtlupd.exe and it contains macros8.dot as well as other Word 97 downloads.

    Thanks,
    Caroline

  10. Super Moderator
    Join Date
    Jan 2001
    Location
    Melbourne, Victoria, Australia
    Posts
    3,381
    Thanks
    3
    Thanked 108 Times in 102 Posts

    Re: Style Identification (2000/SR1)

    Well done - Did you get it to work successfully?
    Andrew Lockton, Chrysalis Design, Melbourne Australia

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •