gustavofarias Posted May 15, 2019 Share Posted May 15, 2019 When I design the report in JasperSoft Studio, in the preview, the column header is repeated for every page, which is ok. If I change the format to XLSx, the same occurs, which is not ok.When I deploy the report to JasperReports Server, the vizualization has repeated column header, which is ok, but when I export to XLSX, the file correctly has no repeated column headers.If I user URL access to generate the report in JasperReportsServer, like this:...flow.html?_flowId=viewReportFlow&reportUnit=/someReport&j_username=anonymousUser&j_password=&output=xlsxThe report has repeated columns headers, which is not ok.So, what should I do to export to XLSX whithout repeating column headers? What JasperReports Server gui do to prevent this? Link to comment Share on other sites More sharing options...
C-Box Posted May 16, 2019 Share Posted May 16, 2019 Have you already tried to set the XLS Export property at (main) jrxml-report ?<property name="net.sf.jasperreports.export.xls.exclude.origin.band.1" value="columnHeader"/>[/code](just change it to xlsx for the newer Excel exporter)Also the jasper-wiki has some nice articles concerning preparing "clean" Excel sheets... e.g. https://community.jaspersoft.com/wiki/xls-export-parameters-jasperreports-server#XLS_Export_Parametershth + regardsC-Box Link to comment Share on other sites More sharing options...
gustavofarias Posted May 16, 2019 Author Share Posted May 16, 2019 By setting "net.sf.jasperreports.export.xls.exclude.origin.band.1", the column header vanished even from first page in xls format.Another solution is to put "print when" = PAGE == 1. But this prevents the header to show in other types of exports where it would be useful on every page. In fact it's easyer to put the headers in the Title band.Anyway, thank you sir, I didn't know about the dozens of Advanced -> Misc -> Edit Properties. There are a lot of interesting properties very useful to excel exporting. Link to comment Share on other sites More sharing options...
C-Box Posted May 17, 2019 Share Posted May 17, 2019 Well I think you coud try to set this property also, to keep just the FIRST columnHeader but remove all FOLLOWING ones:<property name="net.sf.jasperreports.export.xls.exclude.origin.keep.first.band.1" value="columnHeader"/>[/code]hth + regards againC-Box Link to comment Share on other sites More sharing options...
Solution gustavofarias Posted September 29 Author Solution Share Posted September 29 Just add URL parameter &ignorePagination=trueThe report will have just one page, so no reason to have repeated column headers Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now