Click here to Skip to main content
15,891,785 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
Hello,
I am working on a VBA application that extract emails from outlook and does some extra work with the extracted emails. I did it easily by using Outlook API in VBA, but i am facing a problem.
When my applicaion is trying to extract/Read an email from outlook, Outlook displays a warning message i.e
"A Program is trying to access e-mail address information stored in Outlook. If this is unexpected, Click Deny and Verify your antivirus software is up-to-Date."

In this case i have to click on the Allow button every time my application read emails from outlook. Is there any way to stop these warning messages,so that my application can work smoothly without any disturbance.

Thanks All.
Posted

Hi pardeep,

How about trying this :

VB
'First set it to false. This should be your first declaration in the macro.
Application.DisplayAlerts = False;
'Then at the end of the macro, set it to True
 
Share this answer
 
v2
Comments
Pardeep Dhiman 18-Apr-11 3:55am    
thanks for ur suggesion Tarun, but i am not using macro for that, actually i am developing a VBA applicaiion, so the email access code is written in VBA and in it there is no Application.DisplayAlerts property.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900