XML Property
Returns a String representing a sample of the XML that would be passed to the action handler. Read-only.
expression.XML
expression Required. An expression that returns one of the objects in the Applies To list.
Example
This example adds a smart tag to cell A1 and then displays the XML that would be passed to the action handler. This example assumes the host system is connected to the Internet.
Sub CheckXML()
Dim strLink As String
Dim strType As String
' Define SmartTag variables.
strLink = "urn:schemas-microsoft-com:smarttags#StockTickerSymbol"
strType = "stockview"
' Enable smart tags to be embedded and recognized.
ActiveWorkbook.SmartTagOptions.EmbedSmartTags = True
Application.SmartTagRecognizers.Recognize = True
Range("A1").Formula = "MSFT"
' Display the sample of the XML.
MsgBox Range("A1").SmartTags.Add(strLink).XML
End Sub