My project is using Aspose.Email to dragdrop from Outlook. When dragging an entire email message it works OK, and the attachments are available in the MapiMessage’s attachment collection. However, if a user just drags an individual attachment (not the entire message) from Outlook, the dragdrop data contents cannot be converted to a MapiAttachment object using Aspose.Email.Outlook. (It is possible to get the contents directly from the dragdrop event args, but the attachment filename and other attributes is not available). I would like to be able to obtain a MapiAttachment object directly from the attachment stream - there is no MapiAttachment.FromStream method. Is there a way to do this now?
Thank you,
Stephen
Hi Stephen,
Hello Kashif
Thank you for your reply. Since it is possible to drag drop an Outlook email attachment directly to the desktop (or any Windows Explorer folder) and get the attachment contents saved as a file (e.g. Pdf), named with the attachment filename, then the attachment filename and the contents stream must be available in the dragdrop event args. Windows shell knows how to do it. If fact, I have seen articles online that explain how to parse the dragdrop data to get the filename and contents stream (it was a little complicated). I was expecting that the Aspose.Email library could directly convert the Aspose.Windows.Forms.FileDataObject into a MapiAttachment object. However, as I stated in my first post, I don’t see a way to create it, i.e. a MapiAttachment.FromStream method or equivalent would be needed. Please understand, I am not saying that there is an error, I am saying that there is a missing function (feature?) that the library should have. If it does please tell me how to use it.
Thank you,
Stephen
Hi Stephen,
I am afraid to share that I couldn’t find any such method for retrieving attachments and have logged it as an investigation ticket with id: NETWORKNET-34400 in our issue tracking system. As soon as there is some information available in this regard, we’ll update you here via this thread.
The issues you have found earlier (filed as NETWORKNET-34363) have been fixed in this update.
This message was posted using Notification2Forum from Downloads module by Aspose Notifier.
Hello,
I am glad to know that this issue NETWORKNET-34363 has been fixed in the recent release. Partly on the basis of that correction we renewed our maintenance subscription, and I have installed this new version (Aspose.Email 4.3). However I can’t seem to obtain the filename from the filedataobject coming from an Outlook attachment dragdrop operation. Please provide complete code sample (VB preferred) how to process the Outlook dragdrop event args into a stream, and retrieve the Outlook attachment filename. (Usually the attachment we are trying to dragdrop from Outlook is a pdf file and I am also using Aspose.Pdf to convert the stream to a pdf document.)
Thank you,
Stephen
Hi Stephan,
Thank you for your inquiry.
The attachment’s file name issue is logged as NETWORKNET-34400. I have checked the status of this issue and it is planned to be fixed in the Aspose.Email for .NET 4.4.0 version which is due for release by the end of this month. We’ll update you here once there is some information available in this regard and appreciate your patience until then.
Hello Kashif,
I’m confused. In your previous post in this thread you said that this issue was fixed as NETNETWORK-34363 in current release 4.3. Please clarify. Also, in advance of getting the fix in the 4.4 release, please send me example code how to retrieve the dragged attachment file from the filedrageventargs. I have it working OK for dragging the entire Outlook message item, but not sure how to do it for just the attachment file.
Thank you,
Stephen
Hi Stephen,
Hello Aspose Team,
did anything happen on the NETWORKNET-34400 Ticket? Since I have the same Problem. The Aspose.Windows.Forms.FileDataObjectCollection has no FileNames in any Aspose.Windows.Forms.FileDataObject. When I take one or several Emails via Drag Drop OR when I drag one or several Attachments from one Email.
I just renewed our OEM License, please solve this case…
Best regards
Stefan Zabicki
Hi Stefan,