可能的SOAP版本不匹配

cag*_*gin 8 asp.net web-services visual-studio-2008

我的Web服务连接有问题.它说,

可能的SOAP版本不匹配:Envelope命名空间 http://schemas.xmlsoap.org/wsdl/是意外的.期待 http://schemas.xmlsoap.org/soap/envelope/.

当我调用webservice的方法时.你对我的问题有任何想法吗?

Jac*_*ope 1

看起来您在创建 SOAP 信封时提供了错误的命名空间 - 它应该类似于以下内容:

<soap:Envelope xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
               xmlns:xsd="http://www.w3.org/2001/XMLSchema" 
               xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/">
Run Code Online (Sandbox Code Playgroud)

在你的情况下,第三个可能是错误的。