| Author |
Message |
|
|
Post subject: PDF printing from java
Posted: Mar 14, 2006 - 10:24 PM
|
|
Registered Member


Joined: Sep 17, 2005
Posts: 7
|
|
Folks,
Has anybody tried printing PDF Files from Java without using acrobat or 3rd party commercial APIs please? Current Java print API doesn't work.
Cheers,
Chris
:( |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Mar 15, 2006 - 12:27 AM
|
|
Quality Board


Joined: Feb 01, 2004
Posts: 303
|
|
I use iText for my PDF generation needs. |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Mar 15, 2006 - 08:18 PM
|
|
Registered Member


Joined: Sep 17, 2005
Posts: 7
|
|
Thank you Nabil. I also use iText to create the PDF File, but my problem is sending the PDF document to the printer. Latest java print API does not work with PDF. To overcome this problem, I spawn a process to invoke acrobat to print the pdf file. This works fine, but causes various problems especially in the old Windows 98 PCs. Yep, some of my clients still use Windows98 PCs!
So has anybody else been down this route before please?
Thank you,
Chris |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Mar 17, 2006 - 02:52 PM
|
|
Quality Board

Joined: May 23, 2003
Posts: 351
|
|
Wasn't there a separate Acrobat Reader binary Win9x?
Best regards,
Robert |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: Mar 17, 2006 - 02:53 PM
|
|
Quality Board

Joined: May 23, 2003
Posts: 351
|
|
|
|
|
 |
|
|
Post subject:
Posted: Mar 17, 2006 - 10:25 PM
|
|
Registered Member


Joined: Sep 17, 2005
Posts: 7
|
|
Rob,
You are correct, there is a binary Acrobat reader for Win9x, acrobat 5.x to be precise. The problem is sometimes when you change the default printer in Windows, acrobat doesn't pick it up and still points to the old printer. I am forever having to instruct the clients to invoke Acrobat and print a test file manually to show/approve that the problem is with acrobat and not the application. In most cases, I get them to specifically change the printer from acrobat, then invoke the application. This is obviously time consuming and by removing acrobat out of the equation, I will have one less thing to worry about etc.
I am now changing the code to generate a postscript file to see if it works. If it does, then we are in business.
The moral of the story my friends is, stay away from PDF flles if the requirement is to print them from Java, unless of course you buy commercial PDF printing APIs from 3rd part suppliers.
Cheers,
Chris |
|
|
| |
|
|
|
 |
|
|
Post subject:
Posted: May 29, 2006 - 02:36 PM
|
|
Registered Member


Joined: Sep 17, 2005
Posts: 7
|
|
The solution is ..... PDFBox
www.pdfbox.com
Long live OpenSource!
Good Luck |
|
|
| |
|
|
|
 |
|
|