Learn how easy it is to sync an existing GitHub or Google Code repo to a SourceForge project! See Demo

Close

#19 Read Bookmarks

open
nobody
None
5
2007-02-22
2007-02-22
Anonymous
No

I need to read the bookmarks from the pdf & create an index of the bookmarks
Example I have used the pdfbox to actually create the bookmarks in the .pdf and set their titles.

while( currentNode != null ) {
strTitle = currentNode.getTitle();
System.out.println( "Item:" +strTitle );

if(strTitle.equalsIgnoreCase("CMC")){
System.out.println("cmc node");
}
childNode = currentNode.getFirstChild();
while( childNode != null ) {
System.out.println("Child:"+childNode.getTitle());
childNode = childNode.getNextSibling();
}
currentNode = currentNode.getNextSibling();
}

OUTPUT:
Item: Index
Item: CMC
Child: 3.2.S Drug Substance
Child: 3.2.P Drug Product

HOWEVER THE STRING COMPARISION DID NOT WORK ??

Discussion

  •  
    Attachments