Document.SmartTags Property (2007 System)
Gets a SmartTags object that represents a smart tag in a document.
Namespace: Microsoft.Office.Tools.Word
Assembly: Microsoft.Office.Tools.Word.v9.0 (in Microsoft.Office.Tools.Word.v9.0.dll)
Syntax
'Declaration
<BrowsableAttribute(False)> _
Public ReadOnly Property SmartTags As SmartTags
'Usage
Dim instance As Document
Dim value As SmartTags
value = instance.SmartTags
[BrowsableAttribute(false)]
public SmartTags SmartTags { get; }
[BrowsableAttribute(false)]
public:
property SmartTags^ SmartTags {
SmartTags^ get ();
}
public function get SmartTags () : SmartTags
Property Value
Type: SmartTags
A SmartTags object that represents a smart tag in a document.
Examples
The following code example adds properties to the first smart tag in the document. This example assumes that a smart tag exists in the document.
This example is for a document-level customization.
Private Sub DocumentSmartTags()
Dim index As Object = 1
If Me.SmartTags.Count >= 1 Then
Me.SmartTags.Item(index).Properties.Add("President", "true")
End If
End Sub
private void DocumentSmartTags()
{
object index = 1;
if (this.SmartTags.Count >= 1)
{
this.SmartTags.get_Item(ref index)
.Properties.Add("President", "true");
}
}
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see Using Libraries from Partially Trusted Code.