agilaganesh92 Posted February 10, 2015 Share Posted February 10, 2015 hi,Iam new to jasper reports. i am having four variables in summary band which are of sum of unique text fields in the detail band. i need to sum those variables in the summary band. variable1=100(variable class-java.math.Bigdecimal)variable2=100(variable class-java.lang.string)variable3=100(variable class-java.lang.string)variable4=100(variable class-java.lang.string) ___________ 400 ____________ i tried like $v{variable1}+$v{variable2}+$v{variable3}+$v{variable4} in a static text field. it is not giving correct result. Any one help me in resolving this. Thanks in advance. Thanks Link to comment Share on other sites More sharing options...
james.t Posted February 10, 2015 Share Posted February 10, 2015 If you are adding Strings to BigDecimals you will need to do something like this: $V{variable1}.intValue() + Integer.parseInt($V{variable2}) Link to comment Share on other sites More sharing options...
agilaganesh92 Posted February 19, 2015 Author Share Posted February 19, 2015 Thank you for your reply. Iam having another doubt regarding pdf font name attribute. Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now