Search code examples
jasper-reportsexport-to-excel

Jaspererports iReport: split report into several excel sheets on export


I have a report which I created using iReport designer. The report contains 3 datasets and 3 tables, which get filled with data from those datasets. Each table is located in detail band. Our business owner wants these 3 tables to be displayed on 3 different excel sheets upon excel export. I have checked several tutorials and posts, but none of them seems to work for me. Help needed! Thanks in advance!


Solution

  • add pagebreak after each table, then set property

    net.sf.jasperreports.export.xls.one.page.per.sheet to true

    like this

    <property name="net.sf.jasperreports.export.xls.one.page.per.sheet" value="true"/>
    

    for more reference visit this page