Jump to content
Changes to the Jaspersoft community edition download ×

creating new report on hyperlink


Recommended Posts



I have been searching forum for a few hours trying to find out how to create new report on hyperlink click.

I have main report with records containing basic data and i would like to have link for every single record and on its click to be opened new detailed report. Of course, i should also pass some parameters to detailed subrecord.


I create records from Java stanalone application.


Thanks in advance for help!



Link to comment
Share on other sites

  • Replies 5
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic



Check the supplied /demo/samples/hyperlink sample.

Note that it will be some servlet of your own that would answer to those hyperlinks so the URL will be something that you have to design yourself. JR only gives you the mechanism to attach them to text or images in the report.


I hope this helps.


Link to comment
Share on other sites

  • 3 weeks later...

You can add parameters to your hyperlinks in two ways:

  • Simply append GET parameters to the URL, e.g.


    + "&param1=" + $F{field}
    + "$param2=" + $V{var}
    + etc

  • (JR >= 1.2.6) Create a custom hyperlink type and add hyperlink parameters:

    <textField hyperlinkType="MyReportHyperlinkType">
    <hyperlinkParameter name="report">
    <hyperlinkParameter name="param1">


    When you export the filled report to HTML, you'll need to set the JRHtmlExporterParameter.HYPERLINK_PRODUCER_FACTORY parameter to a JRHyperlinkProducerFactory instance that can handle MyReportHyperlinkType hyperlinks.





Post edited by: lucianc, at: 2006/10/24 09:28

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...