xxx.ContentStream - Missing Useful Property

Hi,
Email.Attachment.ContentStream which will return the attachment as stream is a useful property, so we don’t need to save it to MemoryStream and load it back, involving us in SaveOptions and then LoadOptions… which can be destructive!
But my queries:

  1. What’s the MapiAttachment equivalent? MapiAttachment.Content? I hope not, because .Content is defined as Object?!!! If there’s no MapiAttachment equivalent to return the content as memory stream, can I request a MapiAttachment.ContentStream property?

  2. What about the MailMessage/MapiMessage .ContentStream? Can I also request them to be considered?
    Best :slight_smile:

@australian.dev.nerds

We have logged your requirement in our issue tracking system as EMAILNET-40895. You will be informed once there is an update available on it.

Hello,
Any info what’s MapiAttachment.Content ? Same as MailMessage.ContentStream ? If so why defined as generic object ?!

Also can’t add MapiAttachments:
Dim MyMapiAttachment As MapiAttachment
MyMapiAttachment.BinaryData = MyMapiProperty.Data
MyMapiAttachment.DisplayName = “cer.cer”
MAPI.Attachments.Add(MyMapiAttachment)
Of course null exception, but can’t use it any other way to get it work :slight_smile:

@australian.dev.nerds,

Any info what’s MapiAttachment.Content ? Same as MailMessage.ContentStream ?

No. MapiAttachment.Content is a collection of MAPI properties.

Also can’t add MapiAttachments:

Try using overload Add method:

MAPI.Attachments.Add("cer.cer", MyMapiProperty.Data);

Thanks.