【问题标题】:Accessing Exchange Process mailbox using EWS使用 EWS 访问 Exchange 进程邮箱
【发布时间】:2016-10-17 14:30:16
【问题描述】:

我能够创建一个进程邮箱并且我能够通过 https://ExchangeServer/owa/processmailbox@domain.com 然后我将提供我的凭据,然后我就可以登录了。

但我无法通过 EWS 访问。它说 SMTP 地址没有与之关联的邮箱。

我可以使用相同的代码访问我的收件箱..

【问题讨论】:

    标签: c# exchange-server exchangewebservices


    【解决方案1】:

    如果您能够通过交换邮件连接到邮箱,那么您应该能够在 EWS 中执行相同的操作。 创建一个服务 (ExchangeService),您可以在其中使用您的交换凭据登录,然后使用该服务连接到邮箱

    Mailbox mb = new Mailbox("processmailbox@domain.com");
    FolderId fid = new FolderId(WellKnownFolderName.Inbox, mb);
    ItemView view = new ItemView(100);
    
    //use your service to get 100 mails from the mailbox
    var findResults = service.FindItems(fid, view);
    
    foreach (var item in findResults.Items)
    {
        var message = EmailMessage.Bind(service, item.Id, new PropertySet(BasePropertySet.FirstClassProperties, ItemSchema.Attachments));
    }
    

    【讨论】:

    • 是的。我能够从我的 Exchange 客户端连接到进程邮箱。我的主要电子邮件在 office365 上。但无法通过 Office 365 访问进程邮箱。
    • @HariharanNagarajan 但是该进程是否在office365上邮箱?如果您可以通过 EWS 连接到您的 office365 帐户,那么连接到进程邮箱(如果它也在 office365 上)应该不是问题。如果您有连接问题,请阅读此stackoverflow.com/questions/32355440/…
    猜你喜欢
    • 1970-01-01
    • 2012-04-23
    • 2014-12-13
    • 2013-12-02
    • 2011-03-28
    • 2011-08-04
    • 1970-01-01
    • 1970-01-01
    • 2023-03-25
    相关资源
    最近更新 更多