I want to search for an addressEntry object in global address list using below code in C#.
Microsoft.Office.Interop.Outlook.Application app = new Outlook.Application();
Outlook.AddressList gal = app.Session.GetGlobalAddressList();
Outlook.AddressEntry entry = gal.AddressEntries[name];
But i got the 1st matched name which is not correct. I want to pass alias or primarySMTPAddress(mailId) as index which is unique. Give me the method to pass unique value to get exact addressEntry Object. Else method to fetch all the matching addressEntry objects.
And you can suggest the possible index parameters for below snippet.
Outlook.AddressEntry entry = gal.AddressEntries[name];