aspose file tools*
The moose likes JSP and the fly likes Save a JSP page as Word document Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Java 8 in Action this week in the Java 8 forum!
JavaRanch » Java Forums » Java » JSP
Bookmark "Save a JSP page as Word document" Watch "Save a JSP page as Word document" New topic
Author

Save a JSP page as Word document

Pallavi Roy
Ranch Hand

Joined: Jun 01, 2006
Posts: 37
Hi All,

I have .jsp page with some generated content. In that page, there is a button as "save as word". When the link is clicked , i need the save dialog to appear and prompt the user to save the content in the JSP page as word document.How can i do this in JSP.
Please guide me in this regard.

Thanks & Regards,
Pallavi


Break the ice - SCJP 1.4,<br />Where There's a will- SCWCD 1.4.<br />Back in action - Websphere Certified Portal 6 Application Developer
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 60082
    
  65

Once the page has been sent to the broswer, the fact that it was a JSP is moot.

When the button is clicked, a new request will be sent to the server. In this request, a servlet should be called that takes the same data as was sent to the JSP and format it as an RTF document (which is a lot easier to generate than a native Word document).


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Save a JSP page as Word document
 
Similar Threads
creating a text file from JSP
Reading word document
Printing word doucment using JSP
confirmation message
Displaying word doc in web page