Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • paul wheaton
  • Paul Clapham
  • Ron McLeod
Sheriffs:
  • Jeanne Boyarsky
  • Liutauras Vilda
Saloon Keepers:
  • Tim Holloway
  • Carey Brown
  • Roland Mueller
  • Piet Souris
Bartenders:

XSLT format number

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
Hi,

I am trying to format lets say a quantity - In this format number mask I add in any thousand comma sperators that are required. My issue is the numbers after the decimal place. Sometimes I can get 112.8500 returned in the XML. other times I can get 12.54. I can get up to 5 decimal places. So if I pass it through the format-number #,##0.00000 I get trailing zeros added on even if they are not returned in the XML. This is not acceptable. If I try use #,##0.#####, any trailing zeros that are returned in the XML(it does happen), these are knocked off. Any ideas on what sort of a format-number I could use to handle my scenarios?

Any help will be much appreciated,

Sarah
 
author
Posts: 11962
5
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Report post to moderator
I'm closing this thread. Please continue discussion at the duplicate thread in our XML forum.
 
    Bookmark Topic Watch Topic
  • New Topic