[英]How to consume SAP Service Reference from ASPX
我是此類項目的最新成員,我需要一些幫助。 我有一個ASPX應用程序,必須在SOAP上使用SAP Services。 第三伙伴向我提供wsdl文件以附加服務。 好的,當我添加基於WSDL的服務引用時,在我的web.config中添加了下一個文件:
<system.serviceModel>
<bindings>
<basicHttpBinding>
<binding name="ZWSDISLINEPEDIDOS" />
</basicHttpBinding>
</bindings>
<client>
<endpoint address="http://SomeURL" binding="basicHttpBinding" bindingConfiguration="ZWSDISLINEPEDIDOS"
contract="WS_SAP_PEDIDOS.ZWSDISLINEPEDIDOS" name="ZWSDISLINEPEDIDOS" />
</client>
</system.serviceModel>
我的.cs具有下面的代碼:
BasicHttpBinding _Binding = new BasicHttpBinding();
EndpointAddress address = new EndpointAddress("http://SomeURL");
ZWSDISLINEPEDIDOSClient _Client = new ZWSDISLINEPEDIDOSClient(_Binding, address);
_Client.ClientCredentials.UserName.UserName = "MyUserName";
_Client.ClientCredentials.UserName.Password = "MyPassword";
When we try to call a method from the client the next error fires:
“請求的HTTP自動創建客戶端'匿名'的請求。El encabezadoautenticación接收服務器時代'基本領域=“ SAP NetWeaver應用服務器[LP1 / 100]””
任何想法?
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.