在我的VSTO Outlook 2007插件中,我可以获取作为交换用户的收件人的电子邮件地址。但是,当我遇到以下情况时,它不会返回我的smtp电子邮件:获取作为交换用户的收件人的电子邮件地址
- 添加新的Outlook联系人项目(在Outlook联系人中)。
- 此联系人项目的电子邮件地址应该是交换用户(贵组织的任何人员,但是交换用户)的电子邮件地址。
- 现在,当我选择此Outlook联系人作为电子邮件收件人和项目发送事件时,我无法获取smtp地址。
下面是我的代码:
Recipient r = mailItem.Recipients[i];
r.Resolve();
//Note, i have different conditions that check the AddressEntryUserType of recipient's
//address entry object. All other cases work fine. In this case this is
//olOutlookContactAddressEntry.
//I have tried the following:
ContactItem cont = r.AddressEntry.GetContact();
string email = cont.Email1Address;
string emailtmp = r.AddressEntry.PropertyAccessor.GetProperty("http://schemas.microsoft.com/mapi/proptag/0x800F101E") as string;
任何人都可以请帮我,我应该在这种情况下,用什么属性来获取SMTP电子邮件?
我也有这个问题,并不能从收件人的电子邮件或约会项目的SMTP地址。我只能看到这样的地址 - “Address =”/ o = INCORPORATION/ou = Exchange Administrative Group(XXXXXXXXXXXX)/ cn = Recipients/cn = username“' – kavun 2011-07-27 13:27:19