aspose file tools*
The moose likes JSP and the fly likes How do i save a file that has been generated using JSP in excel format . Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "How do i save a file that has been generated using JSP in excel format ." Watch "How do i save a file that has been generated using JSP in excel format ." New topic
Author

How do i save a file that has been generated using JSP in excel format .

Prashanth Vijayai
Greenhorn

Joined: Jul 20, 2007
Posts: 17
Im generating report in jsp ,
I have to save this file in excel format . I tried to save this by using the file option that is File ->Save As but it does not provide me to save it in excel format. How can i save it in excel format.

My second question is that im providing a button saying it as "save" where when i press that button the report that i have mention above should save in excel format . How do i code this using Java coding .

Ulf Dittmer
Marshal

Joined: Mar 22, 2005
Posts: 39544
    
  27
JSPs are generally used for generating HTML. If you want to save it to something Excel can make use of, you need to generate CSV or proper XLS files (for which you'd need to use a servlet - JSPs can't create binary content).


Ping & DNS - updated with new look and Ping home screen widget
Eric Pascarello
author
Rancher

Joined: Nov 08, 2001
Posts: 15376
    
    6
You will need to make a call to the server and have to add these headers to the page

Eric
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: How do i save a file that has been generated using JSP in excel format .
 
Similar Threads
Convert a report in Jsp to PDF format
Convertiing HTML to Excel format.
can we export the data from jsp page to a excel sheet with out a database hit
Download it in different sheets in Excel
How to Export web page(jsp page) to excel using jsp or servlets