[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] Re: How to check if a value is numeric and add 2500 to
Ben Stover wrote:
Assume I have a XML doc which might contain an optional tag with a numeric value similar to Do you use XSLT 1.0 or 2.0? If it is 2.0 then you should decide which one of the numeric types you want to check for e.g. for xsd:decimal <xsl:if test="ns1:aaa and normalize-space(ns1:aaa) castable as xsd:decimal"> <xsl:value-of select="xsd:decimal(normalize-space(ns1:aa)) + 2500"/> </xsl:if> -- Martin Honnen http://msmvps.com/blogs/martin_honnen/
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|