Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Issue with Column footer and Summary bands

I am creating invoices with JasperReports.

I have a Detail section that has the list of all items followed by a column footer which has Totals, Tax etc., and then the return policy in the Summary section.

I want to always ensure that the Detail is followed by Column footer followed by Summary bands. How can we ensure this? I found that sometimes the Summary comes before the Column footer.

Can someone throw some light on this?

like image 600
lakshmi Avatar asked Sep 11 '12 20:09

lakshmi


1 Answers

There really is not much of a solution to this at the moment as it seems to be by-design and not a bug (personally I think they should have an option for this). Your options at the moment though are:

  • Create a Report Group (this is essentially a dummy report group, doesn't really matter). Move your Column Footer contents into the Group Footer band, and leave your Summary in the Summary band. This seemed to work in my limited tests, and I would try it first.
  • Set Float Column Footer and Summary on new Page to true under the main report properties. This has the unfortunate side effect that the summary will always be printed on a second page regardless if everything could fit on one.
  • Set Float Column Footer to true and move your Summary section to the Last Page Footer band. This means it will only be printed once, but the content will be oriented towards the bottom of the last page.

Edit: For the shed some light on this part of the question. It is by design. The Column Footer is seen/treated as essentially a specialized Page footer. So body content (detail band, summary band, etc.) are placed on the page above it always. The only time it does not seem to happen is when the summary is printed on a new page, after the last Column Footer has been printed. So it is by design.

like image 109
Jacob Schoen Avatar answered Oct 10 '22 06:10

Jacob Schoen