Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6691745
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 26, 20262026-05-26T05:47:17+00:00 2026-05-26T05:47:17+00:00

I try to solve this since few days … I get this error only

  • 0

I try to solve this since few days … I get this error only when call soap service, in rest all ok.

My config in client (in service is the same, only not have client section)

<system.serviceModel>
<client>
  <endpoint address="soap" binding="customHttpBinding" bindingConfiguration="MyCustomHttpBinding" name="Soap" contract="ServiceModel.IService" />
</client>
<serviceHostingEnvironment multipleSiteBindingsEnabled="true">
  <serviceActivations>
    <add relativeAddress="Service.svc" service="ServiceModel.Service" />
  </serviceActivations>
</serviceHostingEnvironment>
<bindings>
  <customBinding>
    <binding name="MyCustomHttpBinding">
      <textMessageEncoding messageVersion="Soap12" />
      <context protectionLevel ="None"/>
      <httpTransport transferMode ="Buffered" />
    </binding>
  </customBinding>
  <webHttpBinding>
    <binding name="webHttpBindingSettings" closeTimeout="00:01:00" transferMode="Streamed" openTimeout="00:10:00" receiveTimeout="00:10:00" sendTimeout="00:10:00" maxBufferPoolSize="524288" maxReceivedMessageSize="654321">
      <readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
      <security mode="None">
        <transport clientCredentialType="None" />
      </security>
    </binding>
  </webHttpBinding>
</bindings>
<services>
  <service name="ServiceModel.Service" behaviorConfiguration="MetadataBehavior">
    <endpoint address="soap" binding="customBinding" bindingConfiguration="MyCustomHttpBinding" name="Soap" contract="ServiceModel.IService" />
    <endpoint address="rest" behaviorConfiguration="jsonBehavior" binding="webHttpBinding" bindingConfiguration="webHttpBindingSettings" name="Json" contract="ServiceModel.IService" />
    <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
    <host>
      <baseAddresses>
        <add baseAddress="http://dev.add.com/Service.svc/" />
      </baseAddresses>
    </host>
  </service>
</services>
<behaviors>
  <serviceBehaviors>
    <behavior name="MetadataBehavior">
      <serviceDebug includeExceptionDetailInFaults="true"  />
      <serviceMetadata httpGetEnabled="true" />
    </behavior>
  </serviceBehaviors>
  <endpointBehaviors>
    <behavior name="jsonBehavior">
      <webHttp automaticFormatSelectionEnabled="true" helpEnabled="true" />
    </behavior>
  </endpointBehaviors>
</behaviors>

my service

    [ServiceContract(Namespace = "ServiceModel")]
public interface IService
{
    [OperationContract]
    [WebInvoke()]
    GetInfoResponse GetRestData(GetInfoRequest message);

    [OperationContract]
    [WebInvoke()]
    GetInfoResponse GetSoapData(GetInfoRequest message);

    [OperationContract]
    [WebInvoke(BodyStyle = WebMessageBodyStyle.Wrapped)]
    string Save(Stream message);
}

call service

            GetInfoRequest message = CheckedFields;
        string soap = @"<?xml version=""1.0"" encoding=""utf-8""?>
                <soap12:Envelope xmlns:soap12=""http://www.w3.org/2003/05/soap-envelope"">
                  <soap12:Header>
                    <Action soap12:mustUnderstand=""1"" xmlns=""http://www.w3.org/2005/08/addressing"">ServiceModel/IService/GetSoapData</Action>
                  </soap12:Header>
                <soap12:Body>
            <GetInfoRequest  xmlns=""ServiceModel"">
                <Data xmlns:d4p1=""http://schemas.microsoft.com/2003/10/Serialization/Arrays"" xmlns:i=""http://www.w3.org/2001/XMLSchema-instance""/>
            </GetInfoRequest>
            </soap12:Body>
            </soap12:Envelope>";
        XmlSerializer serializer = new XmlSerializer(typeof(GetInfoRequest));
        HttpWebRequest request = (HttpWebRequest)HttpWebRequest.Create("http://dev.add.renault.com/Service.svc/soap");
        MemoryStream stream1 = new MemoryStream();
        serializer.Serialize(stream1, message);
        stream1.Position = 0;
        StreamReader sr = new StreamReader(stream1);
        string t = sr.ReadToEnd();
        t = t.Remove(0, 22).Trim();
        t = string.Format(soap, t);
        ASCIIEncoding encoding = new ASCIIEncoding();
        request.Timeout = 99999999;
        request.ContentLength = t.Length;
        request.Method = "POST";
        request.ContentType = "application/soap+xml; charset=utf-8";
        request.Accept = "application/soap+xml; charset=utf-8";

        using (Stream stm = request.GetRequestStream())
        {
            using (StreamWriter stmw = new StreamWriter(stm))
            {
                stmw.Write(t);
            }
        }

        var response = (HttpWebResponse)request.GetResponse();
        var abc = new StreamReader(response.GetResponseStream());

Stack Trace

System.ServiceModel.Dispatcher.ErrorBehavior.ThrowAndCatch(Exception e, Message message)
System.ServiceModel.Dispatcher.ChannelHandler.ReplyFailure(RequestContext request, Message fault, String action, String reason, FaultCode code)
System.ServiceModel.Dispatcher.ChannelHandler.ReplyFailure(RequestContext request, FaultCode code, String reason, String action)
System.ServiceModel.Dispatcher.ChannelHandler.ReplyContractFilterDidNotMatch(RequestContext request)
System.ServiceModel.Dispatcher.ChannelHandler.EnsureChannelAndEndpoint(RequestContext request)
System.ServiceModel.Dispatcher.ChannelHandler.TryRetrievingInstanceContext(RequestContext request)
System.ServiceModel.Dispatcher.ChannelHandler.HandleRequest(RequestContext request, OperationContext currentOperationContext)
System.ServiceModel.Dispatcher.ChannelHandler.AsyncMessagePump(IAsyncResult result)
System.Runtime.Fx.AsyncThunk.UnhandledExceptionFrame(IAsyncResult result)
System.Runtime.AsyncResult.Complete(Boolean completedSynchronously)
System.Runtime.InputQueue`1.AsyncQueueReader.Set(Item item)
System.Runtime.InputQueue`1.EnqueueAndDispatch(Item item, Boolean canDispatchOnThisThread)
System.Runtime.InputQueue`1.EnqueueAndDispatch(T item, Action dequeuedCallback, Boolean canDispatchOnThisThread)
System.ServiceModel.Channels.SingletonChannelAcceptor`3.Enqueue(QueueItemType item, Action dequeuedCallback, Boolean canDispatchOnThisThread)
System.ServiceModel.Channels.HttpChannelListener.HttpContextReceived(HttpRequestContext context, Action callback)
System.ServiceModel.Activation.HostedHttpTransportManager.HttpContextReceived(HostedHttpRequestAsyncResult result)
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.HandleRequest()
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.BeginRequest()
System.ServiceModel.Activation.HostedHttpRequestAsyncResult.OnBeginRequest(Object state)
System.Runtime.IOThreadScheduler.ScheduledOverlapped.IOCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
System.Runtime.Fx.IOCompletionThunk.UnhandledExceptionFrame(UInt32 error, UInt32 bytesRead, NativeOverlapped* nativeOverlapped)
System.Threading._IOCompletionCallback.PerformIOCompletionCallback(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-26T05:47:17+00:00Added an answer on May 26, 2026 at 5:47 am

    The problem was that in config I use Soap12 but message which I send using WebHttpRequest contains Soap Header with non Soap12 element.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I have been searching the internet for days trying to solve this problem. I
Sorry to ask this question, but it's now day 3 I try to solve
EDIT 22 March 2011 : This question is no longer that relevant since Youtube
Edit: This has since been solved. Thanks to everyone who helped. Invoking the method
If I write this code: Document d = searcher.doc(docId); d.get(latitude) I get unreported exception
I have been puzzling about retrofitting my app for iCloud for a few days
I get the following error: Exception in thread main java.lang.NoSuchMethodError: com.google.common.collect.ImmutableSet.of([Ljava/lang/Object;)Lcom/google/common/collect/ImmutableSet; at com.google.gdata.wireformats.AltFormat$Builder.setAcceptableTypes(AltFormat.java:399) at
I'm sorry if this has been asked before, but I did try digging through
I've been stuck since several days on my bluetooth application. Its role is to
Every time I tried to connect to the database it give me this error

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.