Hi all!
I've got a question about eval times and bands...
I defined two bands in a report representing even and odd to realize a switch between to different background colours of lines of a table (both bands containing the same text fields but different background colurs). To realize the switch I use "print when expression", e.g. for the evenband
$V{PAGE_COUNT}.intValue() % 2 == 0 ? Boolean.TRUE : Boolean.FALSE
and for the odd band
$V{PAGE_COUNT}.intValue() % 2 == 1 ? Boolean.TRUE : Boolean.FALSE
It works fine for the first page of the report, but not on the following pages - all of the following pages contains the first two lines marked as odd although the value of the first row $V{PAGE_COUNT} is 0 and of the second row is 1, third is 2 and so on...
Could it be possible, that the evalution times are different? What's the matter?
Thanks in advance!
Thomas
I've got a question about eval times and bands...
I defined two bands in a report representing even and odd to realize a switch between to different background colours of lines of a table (both bands containing the same text fields but different background colurs). To realize the switch I use "print when expression", e.g. for the evenband
$V{PAGE_COUNT}.intValue() % 2 == 0 ? Boolean.TRUE : Boolean.FALSE
and for the odd band
$V{PAGE_COUNT}.intValue() % 2 == 1 ? Boolean.TRUE : Boolean.FALSE
It works fine for the first page of the report, but not on the following pages - all of the following pages contains the first two lines marked as odd although the value of the first row $V{PAGE_COUNT} is 0 and of the second row is 1, third is 2 and so on...
Could it be possible, that the evalution times are different? What's the matter?
Thanks in advance!
Thomas
4 Answers:
Posted on August 9, 2006 at 7:54am
Hi Giulio!
Thanks for the quick answer - but it won't help me. Unfortunately the phenomenon doesn't occur if the number of lines in the report page is even. If it's odd - then the expression for the even band will be evaluated to even...
See the attached PDFs for more details...the column NAME contains REPORT_COUNT and PAGE_COUNT - the first file contains a pagefooter and this causes with given dimensions that the number of lines is even. If the footer is removed that number of lines is odd (one more) and this causes the problem...
Thomas
Post edited by: tschuler, at: 2007/03/01 08:53
Thanks for the quick answer - but it won't help me. Unfortunately the phenomenon doesn't occur if the number of lines in the report page is even. If it's odd - then the expression for the even band will be evaluated to even...
See the attached PDFs for more details...the column NAME contains REPORT_COUNT and PAGE_COUNT - the first file contains a pagefooter and this causes with given dimensions that the number of lines is even. If the footer is removed that number of lines is odd (one more) and this causes the problem...
Thomas
Post edited by: tschuler, at: 2007/03/01 08:53