driu Posted June 13, 2011 Share Posted June 13, 2011 hello guys i have a problem with my report.. on my print when expression i have this $F{TIPO_INCASSO}.equals("2")? new Boolean(true) : new Boolean(false)since i want to add another condition..! and i want to become like this:$F{TIPO_INCASSO}.equals("2")? new Boolean(true) : new Boolean(false) && $F{TIPO_1}.equals("C")? new Boolean(true) : new Boolean(false) im encountering an errorThe operator && is undefined for the argument type(s) Boolean, boolean value = (java.lang.Boolean)(new Boolean(((java.lang.String)field_TIPO_INCASSO.getValue()).equals("2")? new Boolean(true) : new Boolean(false) && ((java.lang.String)field_TIPO_1.getValue()).equals("C")? new Boolean(true) : new Boolean(false)));//$JR_EXPR_ID=28$ Any help would be appreciated.. Thanks in advanceDriu Link to comment Share on other sites More sharing options...
thangalin Posted June 14, 2011 Share Posted June 14, 2011 Try: $F{TIPO_INCASSO}.equals("2") && $F{TIPO_1}.equals("C") ? Boolean.TRUE : Boolean.FALSEOr even: new Boolean( $F{TIPO_INCASSO}.equals("2") && $F{TIPO_1}.equals("C") )--Read chapter 15 of Indispensable, a book on JasperReports, available at:http://www.whitemagicsoftware.com/books/indispensable/ Post Edited by thangalin at 06/14/2011 11:22 Link to comment Share on other sites More sharing options...
driu Posted June 15, 2011 Author Share Posted June 15, 2011 Thank you smo much for your answer.. it works fine..!!! would you mind if i ask u another question?? i have 2 column both numeric i want to concatenate and wrap the second column..exampleprice1 || "\n"|| price2Question:what is the oracle function that allows me to wrap the second column?? Thx in andvance 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