How Do I...Debug an XSL Transformation Application?
This sample illustrates how to debug an XSLT application.
VB TransformXML.exe
The Visual Studio debugger can be used to debug an XSLT application. When instantiating the XslCompiledTransform
object, set the enableDebug parameter to true in your code. This tells the XSLT
processor to create debug information when the code is compiled. You can start debugging
as you would with any other application. When you get to the Transform method call, you can
press F11 to step into the code. This loads the XSLT style sheet in a new document window
and the starts the XSLT debugger. You can now set breakpoints in the style sheet, step through the code in the style sheet, and so on.
Note
The XSLT debugger is available in the Professional and Enterprise editions of Visual Studio.
The following code enables debugging on the XslCompiledTransform object.
Dim processor As New XslCompiledTransform(true)
VB
Summary
- The Visual Studio debugger can be used to debug XSLT style sheets or XSLT applications.
- To debug an XSLT application, set the enableDebug parameter to true when instantiating the XslCompiledTransform object. This tells the XSLT processor to create debug information when the code is compiled.
- Set a breakpoint on the Transform method call.
- Start the Visual Studio debugger and press F11 to step into the XSLT code. The XSLT style sheet is loaded in a new document window and the XSLT debugger is started.
Microsoft .NET Framework SDK QuickStart Tutorials Version 2.0
Copyright � 2005 Microsoft Corporation. All rights reserved.
|