Solved

How the hell do you print in Java?!!!

Posted on 1997-11-18
3
183 Views
Last Modified: 2010-04-16
From everything I seen, I am under the impression that you can print from a java application (I'm not worried about printing from applets, yet). I have seen several examples of sample code from people who say the code will print something out to my printer, but NONE of them work. They won't even compile! Whats the deal? Does anyone know how to print? If so, could you please share your knowledge with me? It would be greatly appreciated.

Thanks.  
0
Comment
Question by:johnsm
3 Comments
 
LVL 4

Accepted Solution

by:
russgold earned 100 total points
ID: 1230913
Java printing is a JDK 1.1 feature.  If the samples do not compile on your machine, you are almost certainly using a JDK 1.02 compiler.  Switch to a version of the compiler (and VM) which supports JDK 1.1 and you should find your sample code working just fine.
0
 
LVL 1

Author Comment

by:johnsm
ID: 1230914
I THOUGHT I had downloaded 1.1 only to find out I got 1.0.2. Apparently those bastards lied to me! I now KNOW I have 1.1.4.

Thanks for the insight.

0
 

Expert Comment

by:chocksr
ID: 1230915
Can anyone tell me how to do printing from an Applet?
0

Featured Post

Networking for the Cloud Era

Join Microsoft and Riverbed for a discussion and demonstration of enhancements to SteelConnect:
-One-click orchestration and cloud connectivity in Azure environments
-Tight integration of SD-WAN and WAN optimization capabilities
-Scalability and resiliency equal to a data center

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

This was posted to the Netbeans forum a Feb, 2010 and I also sent it to Verisign. Who didn't help much in my struggles to get my application signed. ------------------------- Start The idea here is to target your cell phones with the correct…
Introduction Java can be integrated with native programs using an interface called JNI(Java Native Interface). Native programs are programs which can directly run on the processor. JNI is simply a naming and calling convention so that the JVM (Java…
Viewers learn about the scanner class in this video and are introduced to receiving user input for their programs. Additionally, objects, conditional statements, and loops are used to help reinforce the concepts. Introduce Scanner class: Importing…
This video teaches viewers about errors in exception handling.

839 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question