We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

NSF to MSG Conversion

We are craeting MSG Files from NSF database, So at the time of creating MSG every part of the email is working fine except the date. and also the MSG which is created is opening in editable mode.

// Create an instance of the Aspose.Email.MailMessage class
MailMessage msg = new MailMessage();
// Set recipients information
msg.To = doc.GetItemValue(“sendto”)[0];
msg.From = doc.GetItemValue(“from”)[0];
msg.Date = doc.GetItemValue(“PostedDate”)[0];

// Set the subject

msg.Subject = doc.GetItemValue(“subject”)[0];

// Set HTML body
msg.HtmlBody = nMime.ContentAsText.ToString();

msg.Save(global_var.msg_eml_path + sba.ToString() + @"" + i + “.msg”, SaveOptions.DefaultMsgUnicode);

Thanks & regards
Mantu Malakar

Hi Mantu,

Thank you for posting your inquiry.

In order to save the message in Sent form, please set the MailMessage.IsDraft property to false. This will also allow you to set date on the message. Please try it at your end and let us know your feedback.

Thank You.
this is working fine.

Thanks & Regards
Mantu Malakar

Hi Mantu,

You are welcome and please feel free to write to us if you have any further query related to API functionality.