In the company we scan documents and then link them up. The main document has
page(s) of selected text linked with external documents which are usualy in
subdirectory. Currently if operator whant to create links from target document
back to main document he/she has to run a small utility developed like 5 years
ago where you have to select which documents you want to link to a certain page.
Then program create bookmarks back to main document. This is very slow specialy
if you have hundreds of document which are sorted alphabeticaly. Long search,
lots of mistakes.
I try to use iText, but my knowledge is still limited. Would be great if
somebody can help little along the path. I want to create small utility where
operator provide location of main document and the utility does all the linking.
I'm familiar with creating bookmarks to document or page in the document.
However I do not know how to retrive information regarding the link from the
page(if present on the page).
I try to do it as follow

PdfDictionary page = pdfReader.getPageN(a);
PdfArray annots = new PdfArray(page.get(PdfName.LINK));
ListIterator linkList = annots.listIterator();
while(linkList.hasNext() )
{
        System.out.println(linkList.next() );
}

Output is NULL, but there are links on the page. 

Where did I go wrong? What shall I do?


-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://itext.ugent.be/itext-in-action/

Reply via email to