System.Xml.Xsl.XslCompiledTransform.Load Method

Compiles the style sheet contained in the System.Xml.XPath.IXPathNavigable object.

Syntax

public void Load (System.Xml.XPath.IXPathNavigable stylesheet)

Parameters

stylesheet
An object implementing the System.Xml.XPath.IXPathNavigable interface. In the Microsoft .NET Framework, this can be either an System.Xml.XmlNode (typically an System.Xml.XmlDocument), or an System.Xml.XPath.XPathDocument containing the style sheet.

Remarks

The System.Xml.Xsl.XslCompiledTransform class supports the XSLT 1.0 syntax. The XSLT style sheet must use the http://www.w3.org/1999/XSL/Transform namespace.

This method has the following behavior:

  • An System.Xml.XmlUrlResolver with no user credentials is used to process any xsl:import or xsl:include elements.

  • The document() function is disabled.

  • Embedded scripts are not supported.

You can use the XslCompiledTransform.Load(System.Xml.XPath.IXPathNavigable, XsltSettings, System.Xml.XmlResolver) overload to specify an System.Xml.XmlResolver with the necessary authentication credentials, or to specify different XSLT settings.

Requirements

Namespace: System.Xml.Xsl
Assembly: System.Xml (in System.Xml.dll)
Assembly Versions: 2.0.0.0, 4.0.0.0
Since: .NET 2.0