I am trying to use the DisplayTag export to excel / csv feature. I am using Spring and Tiles. According to the DisplayTag documentation, I have followed the process recommended and implemented the filter to support tiles. I can view the data. However, the "Export to Excel" button does not work.
In my JSP, I have a search button and based on the input, a list is returned to the same JSP and rendered in a table. When I click on the "Export" button, it returns to the same page but now the table data is no longer visible and the export feature also doesnt work. On the logs, I dont see any exception but I see this message -
ExportDelegate, DEBUG, org.displaytag.filter.ExportDelegate: Filter is enabled but exported content has not been found. Maybe an error occurred?
This is an old topic, but I'll post a solution since someone may have the same problem nowadays, like I did.
I had the same problem a couple of days ago while modifying an old struts 1 application written by some else and it wasn't that easy to find the solution since I'm "new" to struts/jsp. The problem was that the display grid was "buried" under 2 levels of tiles and the filter seemed unable to get rid of the extra html.
My solution was to make a new "view" (forward in struts lingo) for the export, with only the grid and nothing else, and in the action I select this forward when exporting (I used the presence of one of the parameters that displaytag adds to the querystring, "d-49653-e" in my case).