Note

Access to this page requires authorization. You can try signing in or .

Access to this page requires authorization. You can try .

XslCompiledTransform Constructors

Definition

Namespace:
System.Xml.Xsl
Assemblies:
netstandard.dll, System.Xml.ReaderWriter.dll
Assembly:
System.Xml.ReaderWriter.dll
Assembly:
System.Xml.dll
Assembly:
netstandard.dll

Important

Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.

Initializes a new instance of the XslCompiledTransform class.

Overloads

Name Description
XslCompiledTransform()

Initializes a new instance of the XslCompiledTransform class.

XslCompiledTransform(Boolean)

Initializes a new instance of the XslCompiledTransform class with the specified debug setting.

XslCompiledTransform()

Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs

Initializes a new instance of the XslCompiledTransform class.

public:
 XslCompiledTransform();
public XslCompiledTransform();
Public Sub New ()

See also

Applies to

XslCompiledTransform(Boolean)

Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs
Source:
XslCompiledTransform.cs

Initializes a new instance of the XslCompiledTransform class with the specified debug setting.

public:
 XslCompiledTransform(bool enableDebug);
public XslCompiledTransform(bool enableDebug);
new System.Xml.Xsl.XslCompiledTransform : bool -> System.Xml.Xsl.XslCompiledTransform
Public Sub New (enableDebug As Boolean)

Parameters

enableDebug
Boolean

true to generate debug information; otherwise false. Setting this to true enables you to debug the style sheet with the Microsoft Visual Studio Debugger.

Examples

The following example shows how to enable XSLT debugging.

// Enable XSLT debugging.
XslCompiledTransform xslt = new XslCompiledTransform(true);

// Load the style sheet.
xslt.Load("output.xsl");

// Create the writer.
XmlWriterSettings settings = new XmlWriterSettings();
settings.Indent=true;
XmlWriter writer = XmlWriter.Create("output.xml", settings);

// Execute the transformation.
xslt.Transform("books.xml", writer);
writer.Close();
' Enable XSLT debugging.
Dim xslt As New XslCompiledTransform(true)

' Load the style sheet.
xslt.Load("output.xsl")

' Create the writer.
Dim settings As New XmlWriterSettings()
settings.Indent=true
Dim writer As XmlWriter = XmlWriter.Create("output.xml", settings)

' Execute the transformation.
xslt.Transform("books.xml", writer)
writer.Close()

Remarks

The following conditions must be met in order to step into the code and debug the style sheet:

See also

Applies to


Feedback

Was this page helpful?