Posted: 16 May 2017 14:45 EDT Last activity: 6 Nov 2018 20:02 EST
Error Sending Email through Outlook Adapter
I have simple automation which is sending an email using the outlook adapter. But i keep getting a prompt from Outlook, "A program is trying to send an e-mail message on your behalf. If this is unexpected, click Deny and verify your antivirus software is up-to-date". The automation is literally stuck at that location until someone manually hits the "Allow" button(screenshot: Outlook Prompt.JPG attached).
Note. the environment does not allow us to modify the outlook features(Cant take this route)
Another option was, I had outlook launched on MonitorAll as a windows Application adpater and was able to interrogate the alert but the problem is we already have another Application running on MonitorAll and If I'm not wrong we can not have 2 applications. Can you suggest a different way?
**Moderation Team has archived post**
This post has been archived for educational purposes. Contents and links will no longer be updated. If you have the same/similar question, please write a new post.
You can have multiple applications using MonitorAll. The only caveat is that they must be hooking different applications (i.e. you cannot have two MonitorAll adapters hooking IExplore.exe). I think your solution would work fine as it is.
I think you mis-stated that. The solution would need to run first and the Outlook adapter started and running before they launched Outlook. If they are launching Outlook first, then you might need to make it a manual step, or ask them to restart Outlook.
Which version of Outlook are you running? This message appears in certain versions of Outlook to prevent unauthorized emails from being sent without the users knowledge. The other way to send emails is to use the SMTP component. If you are not replying to an Outlook email - just sending an email - this is a lighter alternative.
One thing to consider if you are using the Outlook connector as well as an adapter set to MonitorAll. The connector will likely start Outlook first. In addition, the connector will work if Outlook is running when the solution starts, but the adapter will not. In order for this to work properly, you will need to;
Ensure Outlook is not running when you start your solution.
Ensure your connector has the StartOnProjectStart property set to False.
Use the Started event for the Outlook MonitorAll adapter to Start the Outlook connector.
This will ensure that the adapter is awake and watching for Outlook to be started before the connector actually starts it.