Which Email is selected

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

Which Email is selected

Posts: 171
Joined: 2014-01-05
How do I know which email is selected, I perform various functions with emails whether they be in explorer or inspector windows.

Say I have an inspector window opened and I receive a new email, technically the new email becomes the currently selected email, how can I avoid this.


Posted 19 Jan, 2015 03:30:03 Top
Andrei Smolin

Add-in Express team

Posts: 17178
Joined: 2006-05-11
Hello Tom,

When you select an email, the SelectionChange event occurs on the Explorer object representing the Outlook Explorer window in which you select the email. In add-in Express, this email is mapped to the ExplorerSelectionChange event of the Outlook Events component; you need to put it onto the add-in module.

Starting from Outlook 2010, you can manipulate the selection programmatically, see Explorer.AddToSelection(), Explorer.RemoveFromSelection() and Explorer.ClearSelection() methods.

See also http://msdn.microsoft.com/en-us/library/office/ff868732%28v=office.15%29.aspx.

Regards from Belarus (GMT+3),

Andrei Smolin
Add-in Express Team Leader
Posted 19 Jan, 2015 04:16:03 Top