2004 IR Help Posted August 22, 2006 Share Posted August 22, 2006 By: Vincenzo Amoruso - vinciamo Multiple Copies of a Report 2005-04-04 05:36 Hi! Is there a way to set number of copies to print! i've tried with : PrintRequestAttributeSet aset = new HashPrintRequestAttributeSet(); // Step 2: Obtain a print job. PrinterJob pj = PrinterJob.getPrinterJob(); // Step 3: Find print services. PrintService []services = PrinterJob.lookupPrintServices(); pj.setCopies(2); System.out.println(pj.getCopies()); pj.setPrintService(services[0]); if (PreView) JasperViewer.viewReport(print, PrinterDialog); else { JasperPrintManager.printReport(print, PrinterDialog); } with no results! Thanks in advance! Vince! By: Y-box - y-box RE: Multiple Copies of a Report 2005-04-06 13:19 Won't this work? for(int i = 0; i< numberOfCopies; i++) JasperPrintManager.printReport(jasperPrint, PrinterDialog); y-box By: Vincenzo Amoruso - vinciamo RE: Multiple Copies of a Report 2005-04-07 04:04 OOPS! Simple and Right! Thanks! y-box By: Ruben Misrahi - rnmisrahi RE: Multiple Copies of a Report 2005-07-18 14:25 There is a RequestAttributeSet for this: printRequestAttributeSet.add(new Copies(2)) where printRequestAttributeSet = new PrintRequestAttributeSet() Link to comment Share on other sites More sharing options...
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