471,624 Members | 1,860 Online
Bytes | Software Development & Data Engineering Community
Post +

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 471,624 software developers and data experts.

MailMessage & mime encoded SMTP data

I am trying to build System.Mail.MailMessage object out of mime encoded
SMTP data. I have following questions

Byte[] byteMailData; //mime encoded STMP data for "email with
attachment"

1) MailMessage.Body = Convert(byteMailData);
If I do the above, will MailMessage object extract the Message
BODY, Message HEADER and Attachments automatically.

2) Can MailMessage.Attachemnt() understand MIME encoded attachment
data?
3) Is there a .Net class to decode MIME data?

Thanks
Ramesh

Jan 20 '06 #1
2 2974
Ramesh,

You could not do 1) because you would not be able to assign byteMailData,
which represents an entire message including attachment to just the body
property of a Mailmessage.
For 2), yes the attachment should understand this. I say "should' Because I
am not 100% sure.

For 3) , yes there are custom libraries that encode / decode MIME, but they
are provided by third parties. I have seen at least 2 that are free and
open-source.
Peter

--
Co-founder, Eggheadcafe.com developer portal:
http://www.eggheadcafe.com
UnBlog:
http://petesbloggerama.blogspot.com


"as*******@gmail.com" wrote:
I am trying to build System.Mail.MailMessage object out of mime encoded
SMTP data. I have following questions

Byte[] byteMailData; //mime encoded STMP data for "email with
attachment"

1) MailMessage.Body = Convert(byteMailData);
If I do the above, will MailMessage object extract the Message
BODY, Message HEADER and Attachments automatically.

2) Can MailMessage.Attachemnt() understand MIME encoded attachment
data?
3) Is there a .Net class to decode MIME data?

Thanks
Ramesh

Jan 20 '06 #2
Thank you
Ramesh

Jan 20 '06 #3

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

1 post views Thread by John B. Kim | last post: by
5 posts views Thread by Simran | last post: by
3 posts views Thread by Mike P | last post: by
6 posts views Thread by Frank | last post: by
4 posts views Thread by a | last post: by
2 posts views Thread by Kris Kennaway | last post: by
1 post views Thread by jcor | last post: by
1 post views Thread by XIAOLAOHU | last post: by
reply views Thread by leo001 | last post: by

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.