开发者

Outlook ContactItem: get containing folder?

I am maintaining an Outlook add in that manages Outlook contacts. I have a function that g开发者_如何学Goets all the contacts in a folder and its subfolders. Now, I need to determine which folder a given contact was retrieved from. Is this possible without scanning each of the folders or returning the paths along with each of the contact items?


This works for me:

public string GetFolderFullName(Outlook.ContactItem ci) {
    Outlook.MAPIFolder mf = ci.Parent;
    string path = mf.FolderPath;
    return path;
}
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜