我正在从Excel打开Outlook电子邮件。
我想格式化身体,例如使用某种字体并使一些单词变粗。
以下是我打开电子邮件的VBA代码:
Set OutApp = CreateObject("Outlook.Application")
OutApp.Session.Logon
Set OutMail = OutApp.CreateItem(olMailItem)
With OutMail
.To = strRecipient
.CC = ""
.BCC = ""
.subject = strSubject
.body = strBody
.Display
End With
答案 0 :(得分:1)
您需要使用HTML mail format:
OutMail.BodyFormat = olFormatHTML
OutMail.HTMLBody = "<b>Bold</b>, not bold"