Jump to content
We've recently updated our Privacy Statement, available here ×

when exporting report to excel - column header line disappears


eyale

Recommended Posts

  • 3 weeks later...
  • Replies 7
  • Created
  • Last Reply

Top Posters In This Topic

 i found the answer in on of the posts:

i don't know why (i suggest consider to move this properties to applicationContext.xml file) but some of the xls options

appear in the jasperserver-ce-3.7.1/apache-tomcat/webapps/jasperserver/WEB-INF/classes/jasperreports.properties file

the lines that did the trick are:

# suppress page headers and footers when exporting to XLS 

net.sf.jasperreports.export.exclude.origin.band.1=pageHeader
net.sf.jasperreports.export.exclude.origin.band.2=pageFooter

# this gets rid of the repeating column headers and footers in excel exports
net.sf.jasperreports.export.xls.exclude.origin.band.1=columnHeader
net.sf.jasperreports.export.xls.exclude.origin.band.2=pageFooter

# keep the first column header on export
net.sf.jasperreports.export.xls.exclude.origin.keep.first.band.1=pageHeader

net.sf.jasperreports.export.xls.exclude.origin.keep.first.band.2=columnHeader

thanks.

Link to comment
Share on other sites

  • 2 weeks later...
  • 1 month later...

I'm having the same problem.  Except I have multiple reports, with each having the option to export to .pdf or .xls.  They all export fine to .pdf, only a couple will have column headers when exporting to .xls - and I can't see any obvious differences between the reports that show column headers and those that don't. 

 

I'm using GlassFish 3.0.1 - do you know where would I look to find the same files you highlight?  Thanks.

Link to comment
Share on other sites

  • 2 months later...
  • 1 year later...
In the hope of being helpful, aberrations such as cells or columns not displaying when disposing of a Jasper report to a spreadsheet invariably result from having overlapping fields or fields that accidentally span a section of the report. This is a deficiency in the iReport designer in that it does not bring these matters to the attention of the designer and determining the actual position of fields relative to another can be tricky. It would be better if the properties window of a field not only revealed the left hand side position and width of field in pixels but also the right hand side of the field. There most probably are tricks to doing this but they are just not obvious to new-comers.
Link to comment
Share on other sites

  • 3 years later...

i see the answer below that requires modification to a file on the jasperreport server.  i don't have this luxury.  i don't have access to the server and the admins will not mofidy any files.  

 how do i force the column headers to display, but do so in the .jrxml code?

Thanks

Link to comment
Share on other sites

  • 7 years later...

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 account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...