[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message]

Re: Floating point numbers in msxml xslt processor

Subject: Re: Floating point numbers in msxml xslt processor
From: David Carlisle <davidc@xxxxxxxxx>
Date: Wed, 14 Jun 2006 15:35:59 +0100
msxsl xslt
> is it true that msxml processor does not treat the floating point
> numbers (with scientific notation) like 1.234e-3  as numeric values.

yes the same is true of all XSLT1 processors.  1.234e-3  is a syntax
error in XPath1 (it is floating point syntax in XPath2)

> my client application uses the msxml (Internet explorer 6).
> is there any workaround to make it work.

in pure xslt use substring-after to split on the e and then multiply or
divide by 10 the specified number of times. If you know you are on
msxml, probably simpler just to write an extension function using msxsl:script
in javascript or some such language to just return the number.

David

________________________________________________________________________
This e-mail has been scanned for all viruses by Star. The
service is powered by MessageLabs. For more information on a proactive
anti-virus service working around the clock, around the globe, visit:
http://www.star.net.uk
________________________________________________________________________

Current Thread

PURCHASE STYLUS STUDIO ONLINE TODAY!

Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced!

Buy Stylus Studio Now

Download The World's Best XML IDE!

Accelerate XML development with our award-winning XML IDE - Download a free trial today!

Don't miss another message! Subscribe to this list today.
Email
First Name
Last Name
Company
Subscribe in XML format
RSS 2.0
Atom 0.3
Site Map | Privacy Policy | Terms of Use | Trademarks
Free Stylus Studio XML Training:
W3C Member
Stylus Studio® and DataDirect XQuery ™are products from DataDirect Technologies, is a registered trademark of Progress Software Corporation, in the U.S. and other countries. © 2004-2011 All Rights Reserved.