Hi,
After doing some debugging I kept track for the following information:
Text File:
Content-Type: text/plain
Content-Transfer-Encoding: quoted-printable
This worked perfectly with writing the data being read with a
streamwriter.
GIF:
Content-Type: image/gif
Content-Transfer-Encoding: base64
As suggested converted to base64 and used BinaryWriter, and worked
perfect
Excel:
Content-Type: application/vnd.ms-excel
Content-Transfer-Encoding: base64
As suggested converted to base64 and used BinaryWriter, and worked
perfect
MP3:
Content-Type: audio/mpeg
Content-Transfer-Encoding: base64
As suggested converted to base64 and used BinaryWriter, and worked
perfect
PDF:
Content-Type: application/pdf
Content-Transfer-Encoding: quoted-printable
Tried in both ways (like Text-files, and MP3/GIF/etc) both this file
didn't work and gave an error when tried to open file.
Error given is the following: "There was an error opening this document.
The file is damaged and could not be repaired"
Then I tried another PDF file:
Content-Type: application/pdf
Content-Transfer-Encoding: base64
As suggested converted to base64 and used BinaryWriter, and worked
perfect.
What could the problem be. Could it be that the pdf file is corrupted,
though the original file opens perfectly.
Can someone help me out.
Thanks in Advance
*** Sent via Developersdex
http://www.developersdex.com ***