CustomProperty Object

CustomProperty Object
This content is no longer actively maintained. It is provided as is, for anyone who may still be using these technologies, with no warranties or claims of accuracy with regard to the most recent product version or service release.

CustomProperties
Aa192430.parchild(en-us,office.10).gifCustomProperty

Represents a single instance of a custom property for a smart tag. The CustomProperty object is a member of the CustomProperties collection.

Using the CustomProperty object

Use the Item method — or Properties(Index), where index is the number of the property — of the CustomProperties collection to return a CustomProperty object. Use the Name and Value properties to return the information related to a custom property for a smart tag.  This example displays a message containing the name and value of the first custom property of the first smart tag in the current document. This example assumes that the current document contains at least one smart tag and that the first smart tag has at least one custom property.

  Sub SmartTagsProps()
    With ThisDocument.SmartTags(Index:=1).Properties.Item(Index:=1)
        MsgBox "Smart Tag Name: " & .Name & vbLf & _
            "Smart Tag Value: " & .Value
    End With
End Sub