Start Excel Export from 16th row - Table output or Grid output created using Detail band

0

Hi Folks,

Did anybody try exporting a grid report starting from any custom row number ? Is it possible ?

Thank you in Advance.

 

sadakar's picture
627
Joined: Aug 14 2012 - 3:57am
Last seen: 6 months 1 week ago

2 Answers:

0

Just set the datasource to return from row 16. If you need to export something different from what's displayed in your report, create a new report.

hozawa's picture
42949
Joined: Apr 24 2010 - 4:31pm
Last seen: 5 days 12 hours ago
0

Hi,

This output could be obtained based on print when expressions for elements in the detail band and exporter filter by key properties.

If you need to print out rows starting from 16, for each element in the detail band you need to place 2 textfields: one having the print when expression $V{REPORT_COUNT} < 16 and key="test" setting, the other having the print when expression $V{REPORT_COUNT} > 15 and no key attribute set.

Add these properties in the JRXML file:

    <property name="net.sf.jasperreports.export.xls.exclude.key.test"/>
    <property name="net.sf.jasperreports.export.xlsx.exclude.key.test"/>

Also, the net.sf.jasperreports.export.xls.remove.empty.space.between.rows property should be set in order to remove the empty rows which are generated instead.

I hope this helps,

Sanda

shertage's picture
1917
Joined: Sep 26 2006 - 8:06pm
Last seen: 2 months 3 weeks ago
Feedback