I would like to print multiple pdfs from java (using the java print service) in a single print job.
I would like to send multiple pdfs as a single job to the printer. This is so that all the documents in my 'batch' print together and are not interleaved with someone else's print jobs when I go pick them up from the printer.
A batch potentially consists of 1000s of print jobs.
I tried jpedal, but it does not support java.awt.print.Book
Book book = new Book();
PdfDecoder pdfDecoder = readFileApplyOptions("C:/Temp/singlepagetest.pdf", pageFormat);
book.append(pdfDecoder, pageFormat);
PdfDecoder pdfDecoderTwo = readFileApplyOptions("C:/Temp/printfax-test.pdf",pageFormat);
book.append(pdfDecoderTwo, pageFormat);
printJob.setPageable(book);
printJob.print();
only prints out the first pdf. How do I print multiple pdfs in a single job?
readFileAndApplyOptions() basically creates a new PdfDecoder object and returns it.
I also tried Sun's PDFRenderer PDFRenderer in a similar fashion (using the Book object), but my code still only prints out the first page only.
Has anyone encountered a similar issue before? Is there a solution I might be missing?