Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

JasperReport - different orientation(landscape and portrait) in same report

As asked by few other members, on similar line, I want to have landscape orientation for only one of my subreport. I am using iReport 5.6.0 and JasperReports 5.6.0.

I searched and almost all solutions suggest to have 2 separate reports and add/append them programmatically as mentioned here.

This solution is probably not ideal for me as I have 4 dynamic subreports(can produce variable number of pages at run time) and I want only third subreport to be landscaped. So, at run time it will be difficult to identify the point to append my landscaped report.

Questions that I have:

  1. Is this native feature now introduced in any new version of iReport to support different orientation of subreport?

  2. If no inbuilt support in iReport, how can I programatically add subreport in between, if I don't know at which location/page the subreport will be added.

I tried to look for a solution in JasperSoft Studio as well, but not success.

Thanks in advance.

like image 433
handiekarm Avatar asked Oct 29 '22 22:10

handiekarm


1 Answers

Starting with JasperReports v6.0 you may achieve what you want with a Report Book. It is basically a report bundle where each report can have a different orientation.

But since Jaspersoft Studio(with version 5.5.0) became the official design client for JasperReports, you will not find this feature in iReport. So starting with Jaspersoft Studio v6.0 you will be able to use it.

like image 166
Narcis Avatar answered Jan 02 '23 21:01

Narcis