6

How do I go about adding a Table Of Contents to a Jasper Report?

James McMahon
  • 48,506
  • 64
  • 207
  • 283
  • There is a way with the *Wave Book* from version 6 on, [see more here](https://stackoverflow.com/questions/37862912/data-redundant-after-adding-report-to-report-books). So this would depend on the version you are using. – tobi6 Jul 23 '16 at 09:56

1 Answers1

0

assuming your are using iReport,

for example,

  1. add a text field;
  2. right click, choose hyperlink,
  3. set Hyperlink target to self
  4. and set Hyperlink type to LocalAnchor,
  5. set the anchor value in the Hyperlink Anchor Expression.

after a pdf has been generated, you can click that text field which goes the anchor(bookmark if more precisely)

sadly, I don't think iReport can automatically deduce the TOC in a simple manner. So, you have to add these entries manually.

enter image description here

randomness2077
  • 1,119
  • 2
  • 13
  • 25