Can i print using FIleOutputStream on a printer?
(I am targeting windows platform particularly win32) For example:
FileOutputStream fos = new FileOutputStream("lpt1");
fos.print("testing testing testing testing...");
Will these two lines be able to print on a printer?
If no, please suggest a method.
I think the Printing lesson of Java tutorial trail should help you out. Please post specific questions if it doesn't work.Another link I came across which actually shows you how to "print" a text file, worth a try.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.