• Post Reply Bookmark Topic Watch Topic
  • New Topic

BufferedOutputStream not working for image and *.exe files  RSS feed

 
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi,
I am using BufferedOutputStream for file upload and download in windows. It works fine for writing files to targeted folder with same size, but the problem is *.exe files and image files like *.png,*.jpg are not opening. What method I should use to overcome this issue..
please help me ...
 
Bartender
Posts: 825
5
Java Python Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Check ImageWriter and ImageOutputStream from API, for saving images.
 
saravanan palanivel
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi Kemal,
Will it work for *.txt,*.pdf,*.xls,and *.sitx and other file format?
please..
 
Kemal Sokolovic
Bartender
Posts: 825
5
Java Python Ruby
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

saravanan palanivel wrote:Hi Kemal,
Will it work for *.txt,*.pdf,*.xls,and *.sitx and other file format?
please..



No, these are for images.
To write to txt you can use FileWriter + BufferedWriter. I think that for pdf and xls you'll need to find some third party libraries that support writing in these formats.
 
saravanan palanivel
Greenhorn
Posts: 9
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Kemal,
Thank you very much for your quick response..!
 
Let's go to the waterfront with this tiny ad:
Thread Boost - a very different sort of advertising
https://coderanch.com/t/674455/Thread-Boost-feature
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!