Home All Groups Group Topic Archive Search About

sending email with base64 encoded file

Author
11 Jan 2005 7:21 PM
Damien Debin
Hi,

I have some troubles sending emails with base64 encoded file...
(I use VC# and .Net 1.1)

Doing :

        MailMessage oMessage = new MailMessage();
        oMessage.To = ".**@serensia.com";
        oMessage.From = ".**@serensia.com";
        MailAttachment oMyAttachment = new MailAttachment("file.xml",
MailEncoding.Base64);
        oMessage.Attachments.Add(oMyAttachment);
        SmtpMail.SmtpServer = "mailhub.b3g-telecom.com";
        SmtpMail.Send(oMessage);

This sends an email with file.xml as a an attachment but in "quoted
printable" encoding, not base64 encoding. It works as it should with a binary
file attached but when i try to attach a "text" file (an xml file for
instance), it does not base64 encode it.

Does anybody have the same issue ?

AddThis Social Bookmark Button