【问题标题】:Windows Service to synchronise with Exchange Server Contacts与 Exchange Server 联系人同步的 Windows 服务
【发布时间】:2010-09-24 01:15:32
【问题描述】:
我想编写一个 Windows 服务,它定期将数据库与 Exchange 2007 服务器实例中的联系人同步。
这可以通过 Exchange Web 服务实现吗?或者我可以通过 powershell 来实现吗?
如果我走 EWB 路线,这是否意味着我需要客户端设置 Web Service 端点并使其公开?
客户是公司,将拒绝此请求。有没有更好的办法?
【问题讨论】:
标签:
c#
.net
exchange-server-2007
exchangewebservices
【解决方案1】:
你没有理由不能用 powershell 来做这件事,即使在用 C# 编写的 Windows 服务中也是如此。 Powershell 命令可以通过引用 System.Management.Automation 程序集并使用 Runspace (powershell v1) 或 PowerShell (powershell v2) 类型在进程内组合和执行。