rishikvr Posted December 24, 2014 Posted December 24, 2014 Hi, I am trying to merge multiple .jrxml files and hence multiple pdf's each having different data set into a single pdf . I was able to genereate the single pdf which has all the pdf's generated from .jrxml but the page number is not getting update for the whole document. Ex. i have 1 page in each pdf and even though i have three pages each shows as 1 of 1. How do i update the page number reflecting the total number of pages. Here is my code sample. Thanks for your help in advance.private void exportThePrintList(List<JasperPrint> jasperPrintList, OutputStream output) throws JRException { if(!jasperPrintList.isEmpty()) { JRPdfExporter jrPdfExporter = new JRPdfExporter(); jrPdfExporter.setExporterInput(SimpleExporterInput.getInstance(jasperPrintList)); jrPdfExporter.setExporterOutput(new SimpleOutputStreamExporterOutput(output)); SimplePdfExporterConfiguration configuration = new SimplePdfExporterConfiguration(); configuration.setCreatingBatchModeBookmarks(true); jrPdfExporter.setConfiguration(configuration); jrPdfExporter.exportReport(); } }
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now