How to set the format of an Outlook email message into text plain?

Add-in Express™ Support Service
That's what is more important than anything else

How to set the format of an Outlook email message into text plain?
 
Giancarlo




Posts: 67
Joined: 2016-08-17
I found this sample in C#
https://www.add-in-express.com/creating-addins-blog/2011/09/19/outlook-email-formats-programmatically/

but i can't to translate in Delphi

mail.GetType().InvokeMember(




var
mail: Outlook2010._MailItem
begin
mail.GetType doesn't exist


Can you help me?
Posted 16 Jan, 2017 08:41:25 Top
Andrei Smolin


Add-in Express team


Posts: 14095
Joined: 2006-05-11
Hello Giancarlo,

The C# code demonstrates using late binding to invoke the BodyFormat member, which is missing in the interop assembly (= type library) of Outlook 2000; mail.GetType().InvokeMember("BodyFormat" is the .NET way to do this. Since you use the type library of Outlook 2010 (not 2000), you can invoke that member directly.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 16 Jan, 2017 08:50:50 Top