Please note that Content-Disposition
header is only informative.
What defines the MIME structure are values of used Content-Type
headers.
Unfortunately, every client do it by its own way. If you compare for example Thunderbird
and MS Outlook
you will see other results.
I tried 3 cases with your mail:
1. multipart/mixed
Content-Type: multipart/mixed;
boundary="Apple-Mail-995105A1-ACC6-4F4A-AEE1-3F38A30A09CF"
--Apple-Mail-995105A1-ACC6-4F4A-AEE1-3F38A30A09CF
Content-Type: text/plain;
...
2. multipart/related
Content-Type: multipart/related;
boundary="Apple-Mail-995105A1-ACC6-4F4A-AEE1-3F38A30A09CF"
--Apple-Mail-995105A1-ACC6-4F4A-AEE1-3F38A30A09CF
Content-Type: text/plain;
...
3. multipart/alternative
Content-Type: multipart/alternative;
boundary="Apple-Mail-995105A1-ACC6-4F4A-AEE1-3F38A30A09CF"
--Apple-Mail-995105A1-ACC6-4F4A-AEE1-3F38A30A09CF
Content-Type: text/plain;
...
When I open those mails in MS Outlook, I see:
- and 2. case - "Some preliminary text" as body and two attachments.
- case - "Some preliminary text" as body and no attachments.
The Rebex MailMessage
behavior is as follows:
- case - 1x AlternateViews, 2x Attachments, 0x Resources.
- case - 1x AlternateViews, 0x Attachments, 2x Resources.
- case - 2x AlternateViews, 1x Attachments, 0x Resources.
However, Rebex MailMessage
is .NET library, it does not display emails. What do you mean by "I need a way to display it in our application"?
Basically, all MIME parts can be found in one of the MailMessage
collections (AlternateViews
, Attachments
, Resources
) - based on the Content-Type
used inside the mail.