Jump to content
Changes to the Jaspersoft community edition download ×

how not to print "carryover" on last page

2005 IR Help

Recommended Posts

By: C-Box - c-box

how not to print "carryover" on last page

2004-04-21 05:32



following problem:


I do have a MainReport that has a columheader and a columfooter.

In it's detailband are two subreports that can contain multi pages representing data. (conditional selected by a datafield-value)

if the whole report has more than one page.. there should be a "carryover" of the sum of the line items amount (price.)


on page one there are two line items (100 $ and 50$).. so the carryover for the columnfooter on page one has value 150$...

on page two the carryover of columnheader has also 150 $... now on page two are three line items (75$ , 400$ and 300$)... so the carryover of columnfooter on page two contains the sum of all items = 925$...

and now on page three is the carryover on columnheader also 925$... on the last page (three) just one line item is shown with 1000$ ... so the total sum is 1925$... but I don't need a carryover on columnfooter for that last page (three)...


how can I let vanish the columnfooterband for the last page?

I tried already to use the builtin $V{PAGE_NUMBER} with evaluationtime "report" in a variable within the PrintWhenExpression of the "ColumnFooterBand"


(new Boolean($V{PAGE_NUMBER}.intValue()!=$V{MyMaxPageNumber})


where the reportvariable "MyMaxPageNumber" just should contain the "highest" value of "$V{PAGE_NUMBER} and is evaluated on report time.


But it doesn't work!


For the first page it works well with the columnheader that should just be printed when more than one page is shown (that was easy because I could use a fix value in the PrintWhenExpression --> new Boolean($V{PAGE_NUMBER}.intValue()>1) )....


but how to use that logic for the last page?????


hope for help


Link to comment
Share on other sites

  • Replies 0
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...