【问题标题】:Getting VB to enable Delivery and Read reciepts in MS Outlook Emails让 VBA 在 MS Outlook 电子邮件中启用传递和阅读回执
【发布时间】:2019-01-04 21:21:06
【问题描述】:

我正在使用 Interop 通过 Outlook 发送电子邮件,但我无法指定或启用送达回执和已读回执。

我已经在整个网络上进行了搜索,试图看看这是否可行,但到目前为止,在我的代码生成的电子邮件中操作 Outlook 以启用这些选项方面,我一无所获。

代码:

Dim body As String
Dim objOutlook, objEmail
objOutlook = CType(CreateObject("Outlook.Application"), Outlook.Application)
objEmail = objOutlook.CreateItem(Outlook.OlItemType.olMailItem)
body = "Dear Recipient..."
With objEmail
    .Subject = "Subject..."
    .To = EmailAddresses()
    .Body = body
    '.Attachments.Add(sFilename)
    .Importance = Outlook.OlImportance.olImportanceHigh
    '
    '.**PROPERTIES TO SET DELIVERY AND READ RECEIPTS???**
    '
    'Show on screen
    .Display(True)
    'Uncomment the below to actually send the email
    '.Send()
End With

我的电子邮件工作正常,但我想启用阅读和送达回执选项。有人知道怎么做吗?据我所知,它可能与 _MailItem.OriginatorDeliveryReportRequested 属性有关,但我不太确定如何正确使用它。

谢谢

【问题讨论】:

    标签: vb.net outlook


    【解决方案1】:

    MailItem.ReadReceiptRequestedMailItem.OriginatorDeliveryReportRequested 属性设置为true。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-12-21
      • 2017-09-05
      • 2014-10-16
      • 2014-01-19
      • 2010-10-13
      • 2018-07-08
      • 2020-05-16
      • 2019-11-17
      相关资源
      最近更新 更多