Menu

#140 Reports don't render if currency prefix has special chars

closed
Reports (22)
5
2009-10-30
2009-10-22
No

If the prefix for a currency includes Special Pattern Characters as defined for java.text.DecimalFormat the Jasper reports (like Profit/Loss) fail to render. jGnucash should escape those characters before using the prefix in a pattern for formatting numbers

Discussion

  • Craig Cavanaugh

    Craig Cavanaugh - 2009-10-23

    What currency specifically is causing the problem? Trying to reproduce the problem at my end.

    Thanks

     
  • Craig Cavanaugh

    Craig Cavanaugh - 2009-10-23
    • assigned_to: nobody --> ccavanaugh
     
  • Adrian Gygax

    Adrian Gygax - 2009-10-23
     
  • Adrian Gygax

    Adrian Gygax - 2009-10-23

    Swiss Francs (CHF) is causing the problem for me. If I use the Prefix "SFr." (See screenshot) the reports don't work. If I remove the "." from the Prefix everything works fine. I think the problem happens with any currency if the user uses special chars as prefix-

     
  • Craig Cavanaugh

    Craig Cavanaugh - 2009-10-29

    Thank you, I am able to reproduce the problem now. I will start looking for a solution.

     
  • Craig Cavanaugh

    Craig Cavanaugh - 2009-10-30
    • status: open --> closed
     
  • Craig Cavanaugh

    Craig Cavanaugh - 2009-10-30

    Fix is SVN. Solution was to pass a Format object instead of a String based pattern to the column builder in DynamicJasper. It then correctly handles currency formating internally.

    Thanks again for the bug report and diagnosis of the problem. The root cause would not have been obvious.

    Regards,
    Craig

     

Log in to post a comment.