I have a big report that generate something like 8000 pages. I want to input a limit to maximum page generation. For example to print only the first 100 out of 8000 pages.
I've tried to add net.sf.jasperreports.governor.max.pages and net.sf.jasperreports.governor.max.pages.enabled but it throw a exception and not return only first 100 page.
Adding for all element Print When Expression PAGE_NUMBER < 100 have some big cons:
- Need to sum sub-reports page numbers
- There are a lot of elements and adding Print When Expression to all of them don't looks good
It's not part of the jrxml specification but part of a program that prints the pages.
If you develop your own report printing program using JasperReports library, just specify first page to print and last page to print in JasperPrintManager.printPages() method.