I'm back to this...sorry :)

OK, so I am taking an "original PDF" and copying the Annots array aside 
by using annotInfo = pg1Dict.getAsArray(PdfName.ANNOTS)

But when I go to put it back on a "new PDF" (using reader/stamper), with:
     PdfDictionary pg1Dict = reader.GetPageN(1);
     pg1Dict.put(PdfName.ANNOTS, annotInfo);

I end up with a corrupt /Annots entry.  I am obviously missing something 
or some steps.  Can anyone help with that (admittedly) limited amount of 
info???

Thanks,
AJ


On 2/14/2012 10:41 AM, Leonard Rosenthol wrote:
> Annots array on the Page dictionary.  If you remove that object, you remove 
> all annotations.
>
> (you may also want to, for cleanliness, also remove any AcroForm dictionary 
> off the Catalog object).
>
> Leonard
>
> -----Original Message-----
> From: AJ Weber [mailto:[email protected]]
> Sent: Tuesday, February 14, 2012 10:35 AM
> To: [email protected]
> Subject: [iText-questions] Strip Annotations?
>
> I know there are a lot of different Annotation types, and really I'm 
> interested in stamp/text annots, but in general, is there a way to open a PDF 
> and output the same PDF without any annotations?
>
> I'm using RUPS to view a PDF that has some kind of text annotation/stamp, but 
> I can't find the actual object (even though it's a one-page document and 
> there aren't that many entries in RUPS at all!) to determine exactly what my 
> target object is, so forgive me for being a little vague here.
>
> -AJ
>
>
> ------------------------------------------------------------------------------
> Keep Your Developer Skills Current with LearnDevNow!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-d2d
> _______________________________________________
> iText-questions mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/itext-questions
>
> iText(R) is a registered trademark of 1T3XT BVBA.
> Many questions posted to this list can (and will) be answered with a 
> reference to the iText book: http://www.itextpdf.com/book/
> Please check the keywords list before you ask for examples: 
> http://itextpdf.com/themes/keywords.php
>
> ------------------------------------------------------------------------------
> Keep Your Developer Skills Current with LearnDevNow!
> The most comprehensive online learning library for Microsoft developers
> is just $99.99! Visual Studio, SharePoint, SQL - plus HTML5, CSS3, MVC3,
> Metro Style Apps, more. Free future releases when you subscribe now!
> http://p.sf.net/sfu/learndevnow-d2d
> _______________________________________________
> iText-questions mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/itext-questions
>
> iText(R) is a registered trademark of 1T3XT BVBA.
> Many questions posted to this list can (and will) be answered with a 
> reference to the iText book: http://www.itextpdf.com/book/
> Please check the keywords list before you ask for examples: 
> http://itextpdf.com/themes/keywords.php

------------------------------------------------------------------------------
This SF email is sponsosred by:
Try Windows Azure free for 90 days Click Here 
http://p.sf.net/sfu/sfd2d-msazure
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to