XSLElement Object

SharePoint Designer Developer Reference

Represents an Extensible Stylesheet Language (XSL) element for an XSL Data Form Web Part.

Remarks

Use the all property for the XSLWebPartElement object to return an ElementCollection collection that represents a collection of all the elements for an XSL Data Form Web Part. Then use the tags method to return an ElementCollection collection that represents all of the XSL elements of the specified type ("xsl-template", "xsl-outside-if", "xsl-value-of", and so forth) in a Data Form Web Part. The following example returns the first xsl:template element in the first Web Part in the active document. This example assumes that the first Web Part in the active document is a Data Form Web Part.

Visual Basic for Applications
Dim objWebPart As XSLWebPartElement
Dim objXSLElement As XSLElement
Set objWebPart = ActiveDocument.WebParts.Item(0)
Set objXSLElement = objWebPart.all.tags("xsl-template").Item(0)

See Also