Extracted images are very dark
Submitted by Massimo Lovato on Tue, 01/31/2012 - 23:58Good evening.
I tried to implement listing 15.30 and 15.31 of the book, and images were extracted from a pdf as .jpg files. The problem is that extracted images are very very dark compared to the original pdf. Is there anything I can do to solve this problem?
Thank you
Massimo
Licence of the examples
Submitted by gidoca on Wed, 12/21/2011 - 10:36Unfortunately, I wasn't able to find any information about this: can the examples in the book be modified and reused? If so, under what licence?
How do you flatten a dynamic XFA form?
Submitted by tdubois on Fri, 12/09/2011 - 16:21I have a dyanmic XFA form with a text field and a signature field with reader rights enabled.
I need to make the form read only for non admin users.
when I run the following code:
PdfReader reader = new PdfReader(report.getReportBytes());
reader.removeUsageRights();
ByteArrayOutputStream bao = new ByteArrayOutputStream();
PdfStamper stamper = new PdfStamper(reader, bao);
stamper.setFormFlattening(true);
stamper.close();
report.setReportBytes(bao.toByteArray());
I get the following error when I open the pdf.
How do you flatten a dynamic XFA form?
Submitted by tdubois on Thu, 12/08/2011 - 00:22I have a dynamic pdf with signature fields and text fields on the last page.
If a user downloads the file to view instead of process I want to flatten all of the fields.
Update or remove iText stamp
Submitted by gwmccort on Mon, 10/24/2011 - 16:11How do I identify/update an iText stamp? We are updating our PDF “watermarking” process over to iText. The old application places a key value pair in the stamp which I can identify and remove. I need to be able to do the same thing (i.e. remove or update) the stamp which is created in iText. How would I go about doing this?
Keep small table in a page
Submitted by Jiujing Gu on Mon, 10/17/2011 - 15:41I have a lot of small tables. I want each small table stay on the same page. So, I did the following:
1. create tOuter = new PdfPTable(1);
2. create tInner and added everything I need for the small table into tInner.
3. add tInner into tOuter (tOuter.addCell(tInner);)
4. added tOuter to my document ( document.add(tOuter);)
I thought since tOuter only has one column and one row, it would altomatically stay on the same page. But, it didn't happen.
What should I do?
Thanks in advance.
How can I add/extract document-level attachments to/from an existing PDF file
Submitted by Anonymous on Tue, 10/11/2011 - 15:29I have a PDF file to which I want to add document-level attachments programmatically.
Afterwards, I want to create a tool that allows me to extract these attachments.
Is this possible with iText?
Header vs reorder page for TOC
Submitted by Jiujing Gu on Fri, 10/07/2011 - 22:01Hi Bruno,
I need to create a report with a header on each page, except for the 1st page, which
contains the TOC. I was able to reorder pages with the infomation on page 141. But
when I added the header (page 148), the header was added to the TOC page as well. Also, the
ist non-TOC page did not have the header. What should I do about this?
Thanks in advance for any suggestions.
Jiujing Gu
adding content to cell with simulation
Submitted by xiaoyunwu on Thu, 10/06/2011 - 18:26I have fixed cell width and height, is there anyway for me to add content in there in simulation mode, then if the content can't fit in, I will decrease the font size and add content again?
On page 104 of the book, it says go() method of internal ColumnText method was invoked. If somehow I can know some content was left out, then I will decrease my font size. Thanks for your help.
Reader Enabled Not Working
Submitted by vdunkin on Thu, 10/06/2011 - 17:41I have 2 forms that are reader enabled that I am filling the acroform. The 1st one works without any error, the second gets the pop-up "This document enabled extended features in Adobe Reader ....". I am processing the forms with the same code that sets the PdfStamper to append mode. There is a couple differences that I can find. The one that works, under document properties has the application as Adobe Illustrator CS3 and the producer as Acrobat Distiller 8.1.
