MimePartDisposition Property |
Namespace: MailBee.Mime
For instance, if the header is Content-Disposition: attachment; filename="image.jpg", the attachment value will be returned (additional parameters will be omitted).
If Disposition is inline or missing, this means this MIME part contains a resource which must be rendered when the message body gets displayed. If it's attachment, the resource is a file which does not need to be rendered in order to correctly display the message.
// To use the code below, import MailBee namespaces at the top of your code. using MailBee; using MailBee.Mime; // The actual code (put it into a method of your class). MailMessage msg = new MailMessage(); msg.LoadMessage(@"C:\Docs\TestMail.eml"); Console.WriteLine(msg.MimePartTree.Disposition);