I have a jasper report that consists of 6 subreports. Each of these subreports has its own title section. Now I need each report to start on the new page. I tried adding page breaks but it did not work for me.
While researching the problem I cam across a trick to set isTitleNewPage
to true
at
http://www.dzone.com/snippets/jasperreports-subreport-new. So I added the attribute isTitleNewPage="true"
to all the subreports, but now the subreport's Title remains on the previous page and Details and Summary of that subreport are being displayed on a new page.
How can i solve this problem??
Simplest solution is to set runToBottom
flag to true
in subreport tags.
<subreport runToBottom="true">
This forces the subreport to fill the whole page, so the next subreport will start on a new page.
Flag isTitleNewPage
won't do the trick because like you noticed, it will split the subreport's title band with the rest of the subreport content (unless you're using a blank title band).
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With