I am having reports generated in jsp with HTML codings in tabular format. On report displayed page I have to use one button , which on click has to export to excel sheet.
I tried using below code.
String mimeType = "applicatio n/vnd.ms-excel";
response.setCon tentType(mimeTy pe);
response.setHea der("content-disposition","a ttachment; filename=totalp urgeexcel.xls") ;
But the problem I am facing is , in the report page, header and footer are also their. So while exporting header and footer are also saved in excel.
Another problem is I have a main page where link to particular report is displayed. When I click on one report link itself its showing me popup for saving, its not displaying the report generated page, all datas in that are saving in excel.
Please help me with suitable solution.
I tried using below code.
String mimeType = "applicatio n/vnd.ms-excel";
response.setCon tentType(mimeTy pe);
response.setHea der("content-disposition","a ttachment; filename=totalp urgeexcel.xls") ;
But the problem I am facing is , in the report page, header and footer are also their. So while exporting header and footer are also saved in excel.
Another problem is I have a main page where link to particular report is displayed. When I click on one report link itself its showing me popup for saving, its not displaying the report generated page, all datas in that are saving in excel.
Please help me with suitable solution.
Comment