adxOutlookItemEvents

Add-in Express™ Support Service
That's what is more important than anything else

adxOutlookItemEvents
How to add 
Alex Abramov




Posts: 34
Joined: 2006-09-15
Hi,

How do I add and use adxOutlookItemEvents? (likewise for adxOutlookItemsEvents)

I cannot find how to add it. Would love to read some docs on it or see an example.

TIA,

Alex
Posted 08 Jul, 2010 15:52:24 Top
Andrei Smolin


Add-in Express team


Posts: 15197
Joined: 2006-05-11
Hi Alex,

See Step 13. Handling events of Outlook Items object at Writing Outlook COM add-in in C#, C++, VB.NET.

Regards from Belarus (GMT+2),

Andrei Smolin
Add-in Express Team Leader
Posted 09 Jul, 2010 10:45:34 Top
Alex Abramov




Posts: 34
Joined: 2006-09-15
Andrei,

Thank you.
I would like to look up some info from an old message when someone replies (or forwards) a message and compare it to the new one when it's sent.

It seems the events I need to override would be in OutlookItemEventClass. At which point do I connect to it though?

I am using ADX 2010 (6.0.3043), OL2002/2007, VS2008

TIA,

Alex
Posted 09 Jul, 2010 11:35:50 Top
Andrei Smolin


Add-in Express team


Posts: 15197
Joined: 2006-05-11
Hi Alex,

You need to connect to selected item(s) in ExplorerSelectionChange and to an item in the currently active inspector in InspectorActivate.

There's a problem, however: the user may select an Outlook item, right-click another one and choose Reply or Forward. In Outlook 2007, you handle this scenario by intercepting the ItemContextMenuDisplay event providing the item. This event is missing in all previous Outlook versions, however. You can bypass this by connecting to all items in the current folder but this isn't the best practice because it can be a lot of item in the folder.

Regards from Belarus (GMT+2),

Andrei Smolin
Add-in Express Team Leader
Posted 12 Jul, 2010 05:00:49 Top