Exchange Web Services - The response received from the service didn't contain valid XML

痞子三分冷 提交于 2019-12-05 08:48:39
dabuwang
service.Url = new Uri("https://mail.tencent.com/EWS/Exchange.asmx");

Details info is here: c# programmatically reading emails from the Exchange server

I was experiencing the same issue as described in the following forum post: http://social.technet.microsoft.com/Forums/en-US/exchangesvrdevelopment/thread/e54c217f-28ff-4626-8ce8-a1242081f4d1/

(Essentially extra characters were being pre-pended and appended to the xml returned causing the error above)

If its any help - deleting and re-creating EWS virtual directory did not alleviate the problem.

I believe that perhaps our F5 load balancer or some intermediary device is inserting extra characters at the beginning or end of the XML.

When I changed my code to: service.Url = new Uri("https://192.168.x.x/EWS/Exchange.asmx");

(Essentially using the internal IP address of our exchange server) the request worked just fine. So something outside of exchange is mangling the XML.

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!