loop annotations
René Rakitow <[email protected]> Mon, 11 May 2015 20:03:47 +0000
| Newsgroups | gmane.comp.java.lib.itext.general |
|---|---|
| Message-ID | <[email protected]> |
Hello,
Im trying to loop through the annotations of a pdf and find the name of it and its data
I have the following code;
Private Sub GetAnnots(PdfFile As String)
Dim PdfReader As New PdfReader(PdfFile)
Dim PageDictionary As PdfDictionary = Nothing
Dim AnnotArray As PdfArray = Nothing
Dim Annotation As PdfDictionary = Nothing
Dim PdfString As PdfString = Nothing
Dim AnnotationDictionary As PdfDictionary = Nothing
For page = 1 To PdfReader.NumberOfPages
PageDictionary = PdfReader.GetPageN(page)
AnnotArray = PageDictionary.GetAsArray(PdfName.ANNOTS)
If Not AnnotArray Is Nothing Then
For Each pdfobj As PdfObject In AnnotArray.ArrayList
AnnotationDictionary = DirectCast(PdfReader.GetPdfObject(pdfobj), PdfDictionary)
'' HOW do I go further?
Next
End If
Next
End Sub
Kind regards,
René
------------------------------------------------------------------------------
One dashboard for servers and applications across Physical-Virtual-Cloud
Widest out-of-the-box monitoring support with 50+ applications
Performance metrics, stats and reports that give you Actionable Insights
Deep dive visibility with transaction tracing using APM Insight.
http://ad.doubleclick.net/ddm/clk/290420510;117567292;y
_______________________________________________
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