I want to use PDFBox for printing PDF files created by iText. I have tried this successfully with PDDocument class and its method print(). You can find docu
PDDocument
also offers other print methods than the parameterless print()
:
public void print(PrinterJob printJob) throws PrinterException;
public void silentPrint() throws PrinterException;
public void silentPrint(PrinterJob printJob) throws PrinterException;
The silentPrint
methods don't show the dialog.
You may get what you want by first selecting a printer and then call silentPrint
with PrinterJob
instances initialized accordingly.