aspose file tools
The moose likes Servlets and the fly likes File get currupt if downloaded by response.getOutputStream(); Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login


Win a copy of The Mikado Method this week in the Agile and other Processes forum!
JavaRanch » Java Forums » Java » Servlets
Reply Bookmark "File get currupt if downloaded by response.getOutputStream();" Watch "File get currupt if downloaded by response.getOutputStream();" New topic
Author

File get currupt if downloaded by response.getOutputStream();

Pritish Shirsath
Greenhorn

Joined: Apr 06, 2010
Posts: 1

Hi,
I am trying to download file (of any type pdf/rar/any etc...) using following code,
but SOME TIME downloaded file is currupted.



but when I use


insted of


It works, & download file by name "MyFile" in bin of tomcat folder.
but not work with response object.
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 56179
    
  13

Please UseCodeTags (⇐ click link)


[Smart Questions] [JSP FAQ] [Books by Bear] [Bear's FrontMan] [About Bear]
Devaka Cooray
Saloon Keeper

Joined: Jul 29, 2008
Posts: 2691
    
    3

"Pritish Ss", please check your private messages regarding an important administrative matter.


Author of ExamLab (Download) - the free mock exam kit for SCJP / OCPJP
Home Page -- Twitter Profile -- JavaRanch FAQ -- How to Ask a Question
 
I agree. Here's the link: http://zeroturnaround.com/jrebel
 
subject: File get currupt if downloaded by response.getOutputStream();
 
Similar Threads
Excel file - download
Transfer multiple files from Server to Client using Sockets
Sending a file over socket
Title as PDF file name
getOutputStream() has already been called for this response