Quantcast
Channel: CodeProject Latest postings for ASP.NET
Viewing all articles
Browse latest Browse all 3938

System.ServiceModel.FaultException`1 occurred

$
0
0
I wrote a UPS Rate Quote Service in c# using the supplied WSDL file.
So now I'm testing it, at first the error in transmitting the SOAP file was "An exception has been raised as a result of client data." and the catch would catch it using Exception. Same thing with FaultException.

I read the stack trace, it refers to the Soap call to ProcessRate(Security, Request) in reference.cs and went to line 6492 and 6499.
I wrote another class as the bare minimum and transmitted again and got the same result.

I really don't know how to proceed here.

Soap Call
try
{
   using (var client = new ups_rateService.RatePortTypeClient(new BasicHttpBinding(BasicHttpSecurityMode.Transport), new EndpointAddress(endpointUrl)))
  {   
      pResult = client.ProcessRate(Security, pRequest);
  }
}
catch (Exception e)
{
      Console.WriteLine(e.Message.ToString());
}
Resources.cs
[System.ComponentModel.EditorBrowsableAttribute(System.ComponentModel.EditorBrowsableState.Advanced)]
        Indigo.Services.ups_rateService.RateResponse1 Indigo.Services.ups_rateService.RatePortType.ProcessRate(Indigo.Services.ups_rateService.RateRequest1 request) {
            returnbase.Channel.ProcessRate(request); // line 6492
        }
 
        public Indigo.Services.ups_rateService.RateResponse ProcessRate(Indigo.Services.ups_rateService.UPSSecurity UPSSecurity, Indigo.Services.ups_rateService.RateRequest RateRequest) {
            Indigo.Services.ups_rateService.RateRequest1 inValue = new Indigo.Services.ups_rateService.RateRequest1();
            inValue.UPSSecurity = UPSSecurity;
            inValue.RateRequest = RateRequest;
 
            // line 6499
            Indigo.Services.ups_rateService.RateResponse1 retVal = ((Indigo.Services.ups_rateService.RatePortType)(this)).ProcessRate(inValue);
            return retVal.RateResponse;
        }

Stack Trace
System.ServiceModel.FaultException`1 occurred
HResult=0x80131501
Message=An exception has been raised as a result of client data.
Source=mscorlib
StackTrace:
at System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg)
at System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type)
at Indigo.Services.ups_rateService.RatePortType.ProcessRate(RateRequest1 request)
at Indigo.Services.ups_rateService.RatePortTypeClient.Indigo.Services.ups_rateService.RatePortType.ProcessRate(RateRequest1 request) in J:\Indigo.Services\Service References\ups_rateService\Reference.cs:line 6492
at Indigo.Services.ups_rateService.RatePortTypeClient.ProcessRate(UPSSecurity UPSSecurity, RateRequest RateRequest) in J:\Indigo.Services\Service References\ups_rateService\Reference.cs:line 6499
at Indigo.Services.UPS_Soap_Rate.transmit_request(model_shipRates_rate_request p, RateRequest pRequest) in J:\Indigo.Services\Business Logic\Ship Processors\UPS\UPS_Soap_Rate.cs:line 203
 
If it ain't broke don't fix it

Viewing all articles
Browse latest Browse all 3938

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>