Of course, 'it seems to me that convert a byte array of the contents of a MS DOC file to a string cause error'.
The contents of an MS doc file are not a set of bytes in a single character encoding. They can't be 'converted to a string'. -----Original Message----- From: Daxin Zuo [mailto:[EMAIL PROTECTED] Sent: Friday, October 29, 2004 12:25 PM To: Tomcat Users List Subject: RE: Upload MS DOC or Image file errors. I changed to store the file into a byte array to instead a string. it seems to me that convert a byte array of the contents of a MS DOC file to a string cause error. The byte array is passed to another server via socket. the file is stored at the destination correctly. I use FileOutputStream to see if the buffer stores a file correctly. it is not a necessary part of my application. Thanks. -----Original Message----- From: Steffen Heil [mailto:[EMAIL PROTECTED] Sent: Thursday, October 28, 2004 2:47 PM To: 'Tomcat Users List' Subject: AW: Upload MS DOC or Image file errors. > Thanks. It works. Fine. But what? Switching to FileOutputStream or just using item.write? (They should both work, though the second seems to make more sence. Just asking for interest.) Regards, Steffen --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]