Reputation: 53
I have created a report having a pie chart and I want to open another report when user clicks on a section of a pie chart. Each section will have two different parameters that will be used in another report (that will be opened when user clicks on pie chart).
I have done lot of R&D on hyperlink and link parameter but not succeeded, although hyperlink is working but not able to get link parameters.
I am using iReport 4.7.0 and not using JR Server.
So how can I set and get link parameters?
Upvotes: 1
Views: 3488
Reputation: 3119
In the Chart Data > Details > Section hyperlink you'd need to set the hyperlink type to Reference
(ReportExecution
is JasperReports Server specific).
As hyperlink reference you then can add the link expression e.g.
"http://link/to/report?category=" + $F{category} + "¶m2=" + $P{param}
whereby $F{category}
is a placeholder for the field that the category of the segment in the pie chart and $P{param}
is a placeholder for an arbitrary second parameter.
Upvotes: 1