Hi,
I want to know is there a way to restore Email formatted using RichText formatting? and if yes how?
I have attached a sample email. I found some methods on following links but dont know their usage:
Can you help with this?
Thanks.
Hi,
I want to know is there a way to restore Email formatted using RichText formatting? and if yes how?
I have attached a sample email. I found some methods on following links but dont know their usage:
Can you help with this?
Thanks.
ININPSO:
I want to know is there a way to restore Email formatted using RichText formatting? and if yes how?
Could you please elaborate your requirements to help us assist you further? With respect to the mentioned properties, I was unable to find any working example of these methods and your feedback will enable us to further investigate this requirement.
Hey Kashif,
I will be glad to give you more information but frankly speaking there is not any. I am getting an object for an email which is formatted using “RichText” formatting. The object consists of all the required information about email. I want to reconstruct MSG file using object and save it to hard disk. If possible, I am looking for following steps with code from you.
Hi Jason,
<span style=“font-size:
10.0pt;font-family:“Courier New”;color:blue;mso-no-proof:yes”>string<span style=“font-size:10.0pt;font-family:“Courier New”;mso-no-proof:yes”> dir = “Email_548008\”;<o:p></o:p>
MailMessage msg = MailMessage.Load(dir + "Test RichText formatting.msg");
Console.WriteLine(msg.BodyType.ToString());
MailMessage newMsg = newMailMessage();
foreach (LinkedResource lr in msg.LinkedResources)
newMsg.LinkedResources.Add(lr);
foreach (Attachment at in msg.Attachments)
newMsg.Attachments.Add(at);
newMsg.HtmlBody = msg.HtmlBody;
newMsg.Save(dir + "NewMsg.msg", MailMessageSaveType.OutlookMessageFormatUnicode);
Hi Jason,
<span style=“font-size:
10.0pt;font-family:“Courier New”;color:blue;mso-no-proof:yes”>string<span style=“font-size:10.0pt;font-family:“Courier New”;mso-no-proof:yes”> dir = “Email_548008\”;<o:p></o:p>
MailMessage msg = MailMessage.Load(dir + "Test RichText formatting.msg");
Console.WriteLine(msg.BodyType.ToString());
MailMessage newMsg = newMailMessage();
foreach (LinkedResource lr in msg.LinkedResources)
newMsg.LinkedResources.Add(lr);
foreach (Attachment at in msg.Attachments)
newMsg.Attachments.Add(at);
newMsg.HtmlBody = msg.HtmlBody;
newMsg.Save(dir + "NewMsg.msg", MailMessageSaveType.OutlookMessageFormatUnicode);
The object I am receiving for Email, embedded images are saved in collection named attachments and all images have name exactly same i .e. “Picture (Device Independent Bitmap)”. Just to be clear i am not getting a MSG file but I am getting C#.NET object. I have attached MSG file which i have generated from the .net object. I am not sure how can you recreate the situation I am in because the library is proprietary.
I have also attached original MSG file. This email was translated to .net Object explained above and i want to restore this message but I cant because of the reasons mentioned above.
Can you help me with this?