I read the aritucle in this link:
Class Libraries & REST APIs for the developers to manipulate & process Files from Word, Excel, PowerPoint, Visio, PDF, CAD & several other categories in Web, Desktop or Mobile apps. Develop & deploy on Windows, Linux, MacOS &...
We need to generate an msg file but once is open with outlook we want to send it, the sample code show a outlook screen as it was an email received.
How can i generate an msg file to open with outlook to send it ? … we do not want to reply or forward, we want to send.
This message was posted using Email2Forum by salman.sarfraz.
Thanks for considering Aspose. At the end of the same article, there is an example on saving the msg file in draft mode. This example uses an existing msg file. But you can create a new msg file instead. The sample code would be:
// create msg file string
strMsg = @“test.msg”;
MailMessage msg =
", “subject”, “body”);
// create instance of type MapiMessage from MailMessage
MapiMessage mapiMsg = MapiMessage.FromMailMessage(msg);
// set message flag to un-sent (draft status)
// save it
I figure out after a while. One more thing, after setting an email from the msg file set the from as:
firstname.lastname@example.org [/o=Ariad Custom Communications/ou=Exchange Administrative Group (FYDIBOHF23SPDLT)/cn=Recipients/cn=yusbel] Do there is a workaround or i’m missing something here ? Thanks, Y.
This type of address is set when Exchange Server is used to send/receive emails from Outlook. Could you please manually delete the From address in the msg file using Microsoft Outlook and then check if the email delivers successfully?