Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

Jsp Excel  RSS feed

 
phani kon
Ranch Hand
Posts: 251
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
How would I open the existing xsl file in JSP page ?

I have done like this, but I don't see the contents of the ATREstatsQuarterly2007.xls. This file is located in C: drive.



response.setContentType("application/vnd.ms-excel");
response.setHeader("Content-disposition","attachment; filename= c:\\ATREstatsQuarterly2007.xls");


Can anyone tell what is the wrong in this code please?

Thanks
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you have an existing file, you don't need to set any headers.
Just put it someplace accessible to the web and link to it.
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!