Jump to content
We've recently updated our Privacy Statement, available here ×

Configure BigDecimal-textfield rounding by default


Recommended Posts

Hi!

I need to configure in all my jasper models by default textfield whose expression is a BigDecimal, rounding the value to the upper digit. My textfiled has like pattern "#,##0.00" and it happens that Jasper rounds 0.295 to 0.30, while the sum expression 2.95+0.295 is rounded up to 3.24 instead of 3.25 as desiderable.
 
Is it possible to configure a Jasper parameter so you always have by default the same behavior in a "BigDecimal-textfield" without having to act promptly on each textfield expression in all models [eg. using $V{myVariable}.setScale(2,RoundingMode.HALF_UP)]?
Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...