File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Swing / AWT / SWT and the fly likes Printing Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of REST with Spring (video course) this week in the Spring forum!
JavaRanch » Java Forums » Java » Swing / AWT / SWT
Bookmark "Printing" Watch "Printing" New topic


Ranch Hand

Joined: Nov 22, 2008
Posts: 18944
Using Swing I am doing a program. I have a Text Area where in the Content is Displayed and i want to Print the content of the TextArea once i click the print Button. Can any one help me in Code?
Cindy Glass
"The Hood"

Joined: Sep 29, 2000
Posts: 8521
Do you want to print it to the console (of course not), then to print it to a real printer you have to go through the operating system, so it would depend on your environment.

"JavaRanch, where the deer and the Certified play" - David O'Meara
Frank Carver

Joined: Jan 07, 1999
Posts: 6920
"y sridhar",
The Java Ranch has thousands of visitors every week, many with surprisingly similar names. To avoid confusion we have a naming convention, described at . We require names to have at least two words, separated by a space, and strongly recommend that you use your full real name. Please choose a new name which meets the requirements.

Read about me at ~ Raspberry Alpha Omega ~ Frank's Punchbarrel Blog
Frank Carver

Joined: Jan 07, 1999
Posts: 6920
This is really a question about the Java Printing API rather than Swing/AWT, so I've moved it to the Other Java APIs forum.
I agree. Here's the link:
subject: Printing
It's not a secret anymore!