Search code examples
hyperlinkjasper-reportsjasperserverdrilldown

execute drill down jasper report in pop up JasperReports Server


How to execute drill down sub report as a pop up in the same window?
Now it is drilling down in the same window of JasperReports Server.
Below is the code :

<textField hyperlinkType="ReportExecution"> 
   <reportElement mode="Opaque" x="0" y="0" width="60" height="20" forecolor="#2471D6" uuid="dcbcfbd0-98a4-4c94-a7a5-01ff9bff8db8"/> 
   <textElement textAlignment="Center" verticalAlignment="Middle"> <font isUnderline="true"/> </textElement> 
   <textFieldExpression><![CDATA[$V{resourceunique1}]]></textFieldExpressio‌​n> <hyperlinkParameter name="_report"> 
   <hyperlinkParameterExpression><![CDATA["jrepo:/ca_ppm/ReportsCustom/sub‌​Reports/ResourceCapacityGridByProjectReport"]]></hyperlinkParameterExpression>
</textField>

I need pop up in the parameter "_report" can I directly give the javascript inside the "_report" parameters expression. If so, can you please lead me to achieving it


Solution

  • You can open a report in a popup window by filling in the Hyperlink tab in Jaspersoft Studio with these values. Note you need add your server URL:

    • Link Target: Self
    • Link Type: Reference
    • Hyperlink Reference Expression: "javascript:void(window.open("jasperserver-url/flow.html?_flowId=viewReportFlow&reportUnit=/public/Resources/Reports/ca_ppm/ReportsCustom/sub‌​Reports/ResourceCapacityGridByProjectReport&decorate=no'" +","+"\'\'"+","+"\'height=480,width=950,scrollbars=no,resizable=yes,status=no,toolbar=no,menubar=no,location=no\'"+"));"