View Single Post
  #1 (permalink)  
Old February 10th, 2012, 04:53 AM
chaitali chaitali is offline
Registered User
 
Join Date: Feb 2012
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default how can i download file using struts

i came across the code below and applied in my project
<result name="success" type="stream">
<param name="contentType">application/vnd.ms-excel</param>
<param name="inputName">fileInputStream</param>
<param name="contentDisposition">attachment;filename="fil eABC.xlsx"</param>
<param name="bufferSize">1024</param>
</result>


but the problem is I have my web page(.jsp) which displays a table of 5 columns using <s:iterator> in my jsp file.
I want a download link which will download the table content(that he current page is displaying) and export the records and save in an excel file. please help me.
the file which i want to download is not stored on the server. the table is displayed dynamically via jsp. how can i get the download pop up box without using fileInputStream

Thanks in advance.

Last edited by chaitali; February 10th, 2012 at 04:56 AM..