BizTalk Utilities CV ,   Jobs ,   Code library
 
Home Page


Add/Edit your code items
Search the code library
Browse for the code library


XSLT
Support automatic transformation using XSLT in IE in side by side mode
Displaying XML data in Pages
Repeated search and replace in XSLT
Combinations of k out of n numbers
Permutations of the values of N nodes
DVC Algorithms in XSLT
Another way of avoiding XSLT processor crash
Re: DVC Algorithms in XSLT
trig functions in xslt
XSLT string Replace function
A Slide-In Menu made with XML/XSLT
What is SVG?
Family Tree maker
Alternative Ordering - ""Women and Children to the lifeboats first""
Restructuring flat delimited XML
Hex and Binary Conversions in XSLT - with Boolean math functions
Using XSLT to produce SVG (1)
Using XSLT to produce SVG (2)
Performance Tuning XSLT - Part 1
Performance Tuning XSLT - Part 2


 
 

<< XQuery.NET and XML >>


By Don Kackman
First Posted 10/05/2001
Times viewed 1305

Helpful XSLT ""break"" template


Summary A named template that will halt an XSLT tranformation and reutrn some helpful state information

Debugging XSLT (without the help of cool tools like Xselerator) can be a real pain. This template uses the xsl:message directive to generate a generic error message when you need it. When xsl:messgae terminate=yes is true MSXML creates a COM exception and throws it. This halts the transofrmation and returns control back to the calling function (where ever tranform, transformNode, or transformNodeToObject is being called). The contents of the xsl:message element are returned as the Error.description property. This template packages up some useful information and returns as part of the message. (The path and position templates are based on an earlier snippet by Dimitre Novatchev)

Additional information


Rate this article on a scale of 1 to 10 (0 votes, average 0)

Your vote :  

<< XQuery.NET and XML >>





Leave a comment for this article
Your name
Your email (optional)
Your comment
Optional: Upload an attachment
Enter the code shown:

 
 

    Email TopXML