views:

68

answers:

1

I have a procedure that iterates through the styles available to a document:

Sub EnumerateStyles()
  For Each Style in ActiveDocument.Styles
    `some custom code`
  Next
End Sub

I do not need all the styles, and just those that are applicable to tables only. How can I programmatically filter the styles?

Thank you

A: 

Doh, finally figured out:

Style has the Type property, for the styles applicable to tables it is wdStyleTypeTable.

Vitali Climenco