I've got Postscript code/data (?) in memory (in a Java Tomcat webapp) that I'd like to send directly to a networked PS printer. Is there an easy way (i.e. just popping open a port and sending the text) to print this, bypassing all of the O/S-specific drivers and stuff (and hopefully not even requiring extra jars)? A link to example code showing how to do this?
Thanks, Dave
Share the printer on the primary PCSelect the Start button, then select Settings > Devices > Printers & scanners. Choose the printer you want to share, then select Manage. Select Printer Properties, then choose the Sharing tab. On the Sharing tab, select Share this printer.
At the top of the Security tab, check the Enable Java content in the browser box to enable Java. Uncheck to disable.
Network printers serve multiple computers connected through a common network. This allows multiple computers to print to a single printer, or for multiple printers to share the workload among several computers. A printer can be connected to a network through wired or wireless connections.
open a TCP socket to the LPR port on the target printer.
send your data; as long as the printer comprehends it, you're cool.
don't forget a Line feed when you're done.
(then close the port.)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With