简体   繁体   English

CDO 1.2.1(MAPI)html消息

[英]CDO 1.2.1 (MAPI) html message

I'm developing a C# application that interacts with exchange to send emails. 我正在开发一个与交易所交互以发送电子邮件的C#应用​​程序。 To do that I use CDO 1.2.1 (MAPI) to log into exchange and create the message. 为此,我使用CDO 1.2.1(MAPI)登录到Exchange并创建消息。 The problem is that I need to send a message with HTML body and it seems that is impossible to do this without using the Outlook interop. 问题是我需要发送带有HTML正文的消息,而且如果不使用Outlook互操作,似乎无法做到这一点。

Any way to send an HTML message using CDO 1.2.1 (MAPI) without using the Outlook Interop? 是否可以使用CDO 1.2.1(MAPI)发送HTML消息而不使用Outlook Interop?

Set the PR_)HTML (0x10130102) property using Message.Fields. 使用Message.Fields设置PR_)HTML(0x10130102)属性。 Note that the property is binary (PT_BINARY), so you'd need to convert your HTML data to a hex string first. 请注意,该属性是二进制(PT_BINARY),因此您需要先将HTML数据转换为十六进制字符串。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM