Home > Net >  C # call ws interface problem
C # call ws interface problem

Time:12-11

Interface

?



Soapui test



1 & lt;/errorCode>
Please verify the incoming parameters & lt;/errorMsg>





Vs add web reference
Public class Class1
{
WebReference. Ewell_S50HttpService service=new WebReference. Ewell_S50HttpService ();
Public string triple XML (string) {
WebReference. BS05007 bs=new WebReference. BS05007 ();
Bs. Input=XML;
String ss=service. BS05007 (bs). The output;//this step direct error
Return ss;
}
}
//call
ClassLibrary1. Class1 cl=new ClassLibrary1. Class1 ();
Var a=cl. Aaa (c);
Error message:
Public class Class1
{
WebReference. Ewell_S50HttpService service=new WebReference. Ewell_S50HttpService ();
Public string triple XML (string) {
WebReference. BS05007 bs=new WebReference. BS05007 ();
Bs. Input=XML;
String ss=service. BS05007 (bs). The output;
Return ss;
}
}

The second call
Public class S50Help
{


S50. Ewell_S50Client client=null;
Public string sendbs5007 XML (string)
{

The client=new S50. Ewell_S50Client (new BasicHttpBinding (), new EndpointAddress (" XXXX "));

S50. BS05007 bs5007=new S50. BS05007 ();
Bs5007. Input=XML;
XmlDocument doc=new XmlDocument ();
Var aa=client. BS05007 (bs5007). The output;
Doc. LoadXml (aa. The ToString ());
The return doc. ToString ();
}
}
//call
Ewell_S50_Services. S50Help h=new Ewell_S50_Services. S50Help ();
Var s=h.s endbs5007 (c);
"System.ServiceModel.Com municationException" first chance type of abnormality in mscorlib. DLL in

Other information: to operate "BS05007" an error occurred when a reply message text deserialize,

CodePudding user response:

The bosses to help the problem and see out there, I was directly referenced by vs web services, is not direct execution to method there is success

CodePudding user response:

Web reference normal proxy class is no problem, if you can provide the debug information,

CodePudding user response:

CodePudding user response:

I was directly through vs direct call

CodePudding user response:

See online are set maxStringContentLength length, I also set up or not

CodePudding user response:

Ewel didn't play
  • Related