Hi, almost the code you wrote is a normal code to print docs in java. but the problem is all doc flavaours are not supporetd by all the printers. My printer supports only few. I am not sure about PCL flavour also. Any way will try and see.
Thanks And Regards, Muralidhar Yaragalla. Extranet [EMAIL PROTECTED] 01/26/2008 03:07 AM Please respond to [email protected] To fop-users cc Subject Re: Printing issue Muralidhar, I am also getting same king of problem. I have already existing pdf file. I want to print the pdf file without user interaction. I have goggled and got some information. InputStream is = new BufferedInputStream( new FileInputStream("c:\\test.pdf")); // Here we need to convert pdf to pcl using fop byte[] data = null; /* the fop output */; DocFlavor flavor = DocFlavor.BYTE_ARRAY.PCL; PrintService service = PrintServiceLookup.lookupDefaultPrintService(); DocFlavor[] flavors = service.getSupportedDocFlavors(); // Create the print job DocPrintJob job = service.createPrintJob(); Doc doc = new SimpleDoc(data, flavor, null); // Print it job.print(doc, null); Murali , The above code may gives you some idea to print pdf , but we have to know how to convert PDF file to PCL using FOP. -- View this message in context: http://www.nabble.com/Printing-issue-tp15082765p15097273.html Sent from the FOP - Users mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] This message and any attachments (the "message") is intended solely for the addressees and is confidential. If you receive this message in error, please delete it and immediately notify the sender. Any use not in accord with its purpose, any dissemination or disclosure, either whole or partial, is prohibited except formal approval. The internet can not guarantee the integrity of this message. BNP PARIBAS (and its subsidiaries) shall (will) not therefore be liable for the message if modified. Do not print this message unless it is necessary, consider the environment. --------------------------------------------- Ce message et toutes les pieces jointes (ci-apres le "message") sont etablis a l'intention exclusive de ses destinataires et sont confidentiels. Si vous recevez ce message par erreur, merci de le detruire et d'en avertir immediatement l'expediteur. Toute utilisation de ce message non conforme a sa destination, toute diffusion ou toute publication, totale ou partielle, est interdite, sauf autorisation expresse. L'internet ne permettant pas d'assurer l'integrite de ce message, BNP PARIBAS (et ses filiales) decline(nt) toute responsabilite au titre de ce message, dans l'hypothese ou il aurait ete modifie. N'imprimez ce message que si necessaire, pensez a l'environnement.
