【问题标题】:Error occurs on calling the WebMethod "Client found response content type of 'text/html; charset=us-ascii', but expected 'text/xml'调用 WebMethod 时发生错误“客户端发现响应内容类型为 'text/html; charset=us-ascii', 但预期为 'text/xml'
【发布时间】:2012-02-06 17:09:47
【问题描述】:

我正在调用一个网络方法,该方法将数据集作为我的 Windows Mobile 应用程序的参数。

我收到此错误:

客户端发现响应内容类型为 'text/html; charset=us-ascii', 但应为“文本/xml”。

我不明白确切的错误是什么。

【问题讨论】:

    标签: c# asp.net web-services windows-mobile


    【解决方案1】:

    这是因为 Web 服务返回 text/html 内容的内容类型,而您的移动应用程序期望 xml 可以工作,所以我认为您需要确保您的 Web 服务返回 xml。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2011-06-17
      • 2010-11-05
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多