msolari Posted April 22, 2016 Share Posted April 22, 2016 Hello! i'm new into world to JasperStudio. I have a table where the all cells have the styled borders. Within, the "text fields" it automatically resize if necessary. One of these fields, has value string empty, by my function case WHEN ({field} = null) THEN ' ' ELSE {field} || ... (etc.) end The problem is that the "text field" seems not rendered with string empty, although isBlankWhenNull="false", and i have this unpleasant effect. * Into image i have forced backgroud-color red, for let you see that "text field" is not rendered. Is possible constrain the render also is string empty? Or there are other solutions. Thanks in advance. Link to comment Share on other sites More sharing options...
hozawa Posted April 22, 2016 Share Posted April 22, 2016 Not sure what you're trying to do but JasperReports seems to be working as you've specified. Why are you setting value to blank when null instead of isBlankWhenNull = true? I'm not sure of what you're trying to do but if you just want to have empty bordered cell, place a static text over the text box and set Print When Expression so that static text will be printed on the field is null and text field not printed when the value is null. Link to comment Share on other sites More sharing options...
kkriplani Posted April 22, 2016 Share Posted April 22, 2016 Hi, Could you please explain better about your requirement?Regards,KKriplani Link to comment Share on other sites More sharing options...
msolari Posted April 22, 2016 Author Share Posted April 22, 2016 To answer your question: Why are you setting value to blank when null instead of isBlankWhenNull = true? i started with isBlankWhenNull="true", for avoid the print "null" into field, but i obtained the same unpleasant effect that i have now. My solution is manage the value, with string empty, before to be processed by jasper. The problem seems be that the "text field" if it find "string empty", It treats him as NULL and not print the value. The background-color of text field, shows that the element it is not rendered. Your idea is good, a bit it me bothers duplicate all fields for manage a value that could be print how to received. Thanks hozawa Link to comment Share on other sites More sharing options...
msolari Posted April 22, 2016 Author Share Posted April 22, 2016 Actually i forgot, a detail important. The anomaly, is present only if the thext fields, of same row, they resize. If this does not happen, everything works. Link to comment Share on other sites More sharing options...
msolari Posted April 22, 2016 Author Share Posted April 22, 2016 My scope is avoid, in case of downsizing of the fields for the content, that is shown cell border, since into first two cells the value is string empty, seems the text field is not rendered 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