Reputation: 150
I need to select a mailitem from my outlook add-in. I'm trying to use
Outlook._Explorer explorer = OutlookApp.ActiveExplorer();
explorer.AddToSelection(item);
and it's ok, but only if "Show as conversations" flag is not checked. When it's checked, i'm getting an error "The method you are invoking is invalid for a conversation view." How can i select a mailitem, when "Show as conversations" flag is checked?
Upvotes: 0
Views: 675
Reputation: 5834
AFAIK, you can use AddToSelection when Conversations are enabled. However there are a number of other conditions outlined in the link below that could prevent it from working. Just make sure to call Explorer.IsItemSelectableInView(Item) before calling AddToSelection.
Explorer.AddToSelection Method (Outlook) http://msdn.microsoft.com/en-us/library/office/ff868732(v=office.15).aspx
Upvotes: 1