本文介绍了如何以编程方式停止OutLook安全消息:程序正在尝试访问电子邮件地址,允许访问1分钟的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何停止OutLook安全消息:

How to stop OutLook Security Message :

我想以编程方式停止此警报,并希望允许vba访问Outlook的收件箱,因为我没有Outlook的管理员访问权限,所以我无法手动解决此问题,而是信任Outlook中的中心设置

I want to stop this alert programatically and want to allow vba to access inbox of outlook,, since I dont have admin access for the outlook, I cant solve this manually going to trust center settings in outlook

我的代码工作得很好,但是操作安全性消息需要一次又一次地检查访问权限10分钟

My code works perfectly fine but op up security msgs need to check access for 10min again and again

使用excel vba,我正在访问Outlook邮件并从邮件中下载附件

Using excel vba I'm accessing outlook mails and downloading attachments from mail

Dim sa, ba As Date
Dim spa As Date

Set ObjO = CreateObject("Outlook.Application")
Set olNs = ObjO.GetNamespace("MAPI")
Set objFolder = olNs.GetDefaultFolder(6)

Debug.Print objFolder

spa = Date

Dim j
j = 0

For Each item1 In objFolder.Items

    sa = Format(item1.ReceivedTime, "dd-MM-yyyy")

    If sa <= spa Then
         If sa > spa - 30 And item1.SenderName = "PUJARY, SHRIKANTH" Then

在执行item1.senderName行时,会弹出安全警报

At execution of item1.senderName line that security alert is popping up

推荐答案

如果使用兑换是一个选项,在几个地方修改脚本会使脚本在没有安全提示的情况下运行:

If using Redemption is an option, modifying your script in a couple places would make it run without security prompts:

dim sItem
set sItem = CreateObject("Redemption.SafeMailItem")
For Each item1 In objFolder.Items
    sItem.Item = item1
    sa = Format(item1.ReceivedTime, "dd-MM-yyyy")
    If sa <= spa Then
         If sa > spa - 30 And sItem.SenderName = "PUJARY, SHRIKANTH" Then

这篇关于如何以编程方式停止OutLook安全消息:程序正在尝试访问电子邮件地址,允许访问1分钟的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

11-01 06:18