Reputation: 842
I am trying to make a PDF file. And also the notes documents are the contents. I have a clear idea with iText.
But is there any other solution for making PDFs without using iText?
Upvotes: 1
Views: 2229
Reputation: 20384
Apache FOP using XSL:FO is a way you can generate PDF (and other formats) from XPages. I'm in the process to write an article series on my blog detailing my approach and solution. Ultimately, once I got the spare time, I'll bundle all up and release it on OpenNTF
Upvotes: 3
Reputation: 1074
I have used the FDF format to populate PDF template forms.
Create yourPDFTemplate.pdf and attach it to the database as a file Add a field "Name" to it and when you call the agent it will open the PDF file and fill the field with MarkyRoden
This is the lotusscript equivalent which could just as easily be done as an xAgent if you wanted to. If anyone wants me to I can create an example easily enough. Replace "MarkyRoden" with data from a notesdocument
Dim session As New NotesSession
Print |Content-type: application/vnd.fdf|
Print |%FDF-1.2|
Print |1 0 obj <<|
Print |/FDF <<|
Print |/Fields|
Print |[|
Print |<< /T (Name) /V (MarkyRoden) >>|
Print |]|
Print |/F (http://yourserver.com/mark/testing.nsf/yourPDFTemplate.pdf)|
Print |>>|
Print |>>|
Print |endobj|
Print |trailer|
Print |<< /Root 1 0 R >>|
Print |%%EOF|
End Sub
Upvotes: 1
Reputation: 6936
You can give Apache PDFBOX a try. I used it to export text contents and it worked just fine. Also it is available under Apache license so it can be used in proprietary software unlike iText which is available under Afero GPL which is restrictive than Apache license. On the downside Apache PDFBOX is less mature than iText so it has less features and documentation available.
Upvotes: 2
Reputation: 8465
There is a custom control on openntf that converts data into pdf's.
Edit: My mistake this also uses iText.
Upvotes: 1