如何从组织外部删除传入邮件正文中的警告集

时间:2019-06-10 20:55:20

标签: html vba outlook outlook-vba

我正在尝试删除由本地政策设置的警告,该警告会向来自组织外部的所有入站电子邮件的正文添加警告。

这使电子邮件的摘要窗格模糊,并带有相同的警告,我无法确定电子邮件是否适合我。

我尝试过:

Private Sub Application_ItemSend(ByVal Item As Object, Cancel As Boolean)

    Item.HTMLBody = Replace(Item.HTMLBody, "CAUTION: This email originated from outside of the organization. This message might not be safe, use caution in opening it. If in doubt, do not open the attachment nor links in the message.", "")

End Sub

但是没有成功。

这是添加到每封电子邮件中的警告html:

<div style="background-color:#FFEB9C; width:100%; border-style: solid; border-color:#9C6500; border-color:#9C6500; border-width:1pt; padding:2pt; font-size:10pt; line-height:12pt; font-family:'Calibri'; color:Black; text-align: left;">

<span style="color:#9C6500; font-weight:bold;">CAUTION:</span> This email originated from outside of the organization. This message might not be safe, use caution in opening it. If in doubt, do not open the attachment nor links in the message.</div>
<br>

作为最佳情况,我需要将其完全删除,或者仅删除文本,以免使我的摘要阅读窗格模糊在Outlook或电话上。

0 个答案:

没有答案