We developed some servlets to manage pdfs using mainly iText-2 and pdfbox libraries.
One of them merge some existing pdfs, generate a frontpage, an index and add some other cutomization then return resulting file.
Attached zip contains:
- eclipse project with full source (eclipse_project subdir)
- external libraries jars (external_libs_jars subdir)
- compiled war ([url removed, login to view] file)
- some example original pdfs with resulting defecting generated pdf (test
The problem is that the index doesn't work. We would like that with a click onto the title in the index acrobat goes on the right page. Current index contains page number but need to be clickable similar to outline.
Method that generate index is [url removed, login to view](..)
method to work on is only generateIndexInternal(..)
this method is currently using iText and order and grouping logic is outside that method so you don't need to work in order and grouping logic.
I think main problem is that index is generated as a single pdf file and then merged with other pages so we need to target click to pagenumber when page still is not there.
Pages referred by index are added later.
We think it can be solved in this way:
You can change entirely [url removed, login to view](..) creating an open iText document, adding frontpage if needed, index in needed, all single pdfs and needed customizations (page number and image) and only then close the document so index ca contain references to pages.
Then you need to check generated document total number of page to verify it match calculated one because an index longer than expected can invalidate pagenumbers in index row.
If page number don't match you need to adapt initialPageShift in index and recreate all above document.
At last you have to add outline if needed.
We don't need to find another way to solve a problem or a suggest.
We need that the software works like is.
We need to solve to problems with this software. The problem must be solved in three days.
Here you can find software:
[url removed, login to view]
For award is evaluated in order a short description of how you want to solve,
no details, but just for understand you know the problem, the fast, e he price.