Gabriel H
Gabriel H

Reputation: 1576

Extend outlook rules Actions using vsto

I Want to create custom code that will run when the user decides based on outlook's rules.

so far i checked a few possibilities:

1)Create a custom Action that would be added to the rules actions options - that is not possible according to MS - https://social.msdn.microsoft.com/Forums/vstudio/en-US/1bae2bbc-0ab4-419a-b0d6-7a02195348ce/outlook-custom-action-in-rules-wizard?forum=vsto

2)Run Script based on a rule - built in ability, however i encountered a few issues:

I want to use the C# VSTO add-in in order to overcome those problems: Is there a way to implant the script and make sure the macro is enabled using a VSTO add-in?

this way users will be able to install the add-in and then chose the script as an action to every rule they create based on the default outlook rules.

Upvotes: 0

Views: 258

Answers (1)

Dmitry Streblechenko
Dmitry Streblechenko

Reputation: 66306

You don't need a rule if your code is in a VSTO addin. You can use Items.ItemAdd event on the Inbox folder or Application.NewMailEx event to so anything your please with the newly arrived message.

Upvotes: 0

Related Questions