WSDL链接中是否存在语法错误?如果存在参考[...]

问题描述 投票:0回答:1

我收到了一个以“?WSDL”结尾的Web服务URL,它允许我通过Web访问XML文件。

我的任务是将值发送到Web服务并获得响应,但我在使用PowerShell连接它时遇到问题。我上周管理了一个连接,但在复活节假期之后,很可能在另一方的网络服务上有一些变化。现在,当我尝试连接到Web服务时,我收到以下错误。

见图。

The error message: if ref is present, all of [...] must be absent

我测试没有参数:-UseDefaultCredential-Namespace,错误仍然是相同的

$HACWS = New-WebServiceProxy -Uri $UriLong
New-WebServiceProxy : Schema item 'element' named 'RadarDeployResponse' from
namespace 'urn:RadarDeploymentTNS'. If ref is present, all of <complexType>,
<simpleType>, <key>, <keyref>, <unique>, nillable, default, fixed, form, block,
and type must be absent.
At line:2 char:16
+ ...  $WsShort = New-WebServiceProxy -Uri "http://hssdas515:8090/Ivory/soa ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : NotSpecified: (:) [New-WebServiceProxy], InvalidOperationException
    + FullyQualifiedErrorId : System.InvalidOperationException,Microsoft.PowerShell.Commands.NewWebServiceProxy 
xml powershell webservice-client
1个回答
0
投票

我通过联系我试图连接的Web服务的创建者解决了我的错误。显然,xml元素中存在语法错误。错误消息非常明确。

© www.soinside.com 2019 - 2024. All rights reserved.