I am using displaytag1.1, and working with Excel export. The data portion of the list is exporting correctly, but I am having trouble exporting a caption into Excel. I don't want to display the caption on the jsp page - only in the Excel export file.
 
Here is how I set up the tag:
 
<display:caption media="excel">User List</display:caption>
 
And here is my displaytag.properties file:
 
export.types=excel
export.decorated=true
export.excel=true
export.csv=false
export.xml=false
export.pdf=false
export.excel.class=org.displaytag.export.ExcelView
export.excel.filename=test.xls
export.excel.include_header=true
export.excel.label=<img src="" border="0" alt="">&nbsp;Excel
export.banner=<div class="exportlinks">Export to: {0}</div>
 
The data columns and header info are exported correctly, but the caption does not. If I change the media attribute to include both html and excel, the caption shows in the jsp page, but still not in the excel file.
 
I also notice that the file being generated in Excel is named a little oddly - it shows as test[1].xls
 
This is in a Struts 1.2.7 app, using Tiles, and I have added an export filter to web.xml file
 
Any insight or guidance as to how to get the caption into Excel would be appreciated.... thanks!
 
Regards,
 
--Chris

Reply via email to