swelch Posted March 3, 2011 Share Posted March 3, 2011 Hello. I have a report with fields holding numeric data, namely a 0 for false and a 1 for true. I would like to display the result as a check box but this looks difficult so the other option would be to have the report show a 'Green' box for a 1 and a 'red' box for a 0. How is this done easily? I have tried adding a conditional expression '$F {Filed_Name}.equals('1') but the system does not like either '1' or "1".Any ideas? Kind Regards,S Welch Link to comment Share on other sites More sharing options...
baggypants Posted March 3, 2011 Share Posted March 3, 2011 I find it's down to type casting. by putting the 1 in quotes you're trying to say it's a String when you want it to be a number. Try either not having any quotes at all or casting it properly with $F {Filed_Name}.equals(new BigDecimal(1))or$F {Filed_Name}.equals(new Integer(1)) 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