tomcat-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From JBraw...@silenus.com
Subject JSP/Servlet Printing
Date Tue, 21 Aug 2001 20:13:05 GMT
This is a question I posted in Sun's Java Forums and got no replies.  I
really need a solution and was hoping someone in this group could help out.

I have an Apache/Tomcat webserver on a standalone touchscreen kiosk. The
customer would like a print button on every jsp and, when touched by the
user, would like the page printed.  How do I do this?

1. I've tried the javascript print() method but I DON'T want the print
dialog to appear.  I want to print directly to the default printer.  Is
there a way to bypass the print dialog?

2. Also, in the servlet, I've tried to populate a JEditorPane with the html
and print it using the awt.print stuff.  But that doesn't work.  Is there a
trick to getting that working within a servlet?

Does anybody know how I can accomplish this by using the two approaches
I've listed or any other way?

Thanks,
JEB



Mime
View raw message