Click here to Skip to main content
15,881,803 members
Please Sign up or sign in to vote.
4.00/5 (1 vote)
See more:
There was no endpoint listening at http://localhost:4753/Service1.svc that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.

I had check my ServiceReference.ClientConfig

HTML
<configuration>
    <system.servicemodel>
        <bindings>
            <basichttpbinding>
                <binding name="BasicHttpBinding_IService1" maxbuffersize="2147483647">
                    maxReceivedMessageSize="2147483647">
                    <security mode="None" />
                </binding>
            </basichttpbinding>
        </bindings>
        <client>
            <endpoint address="http://localhost:4753/Service1.svc" binding="basicHttpBinding">
                bindingConfiguration="BasicHttpBinding_IService1" contract="ServiceReference1.IService1"
                name="BasicHttpBinding_IService1" />
        </endpoint></client>
    </system.servicemodel>
</configuration>


The error(bold font) occur is after i add one data into sql server.

C#
public System.Collections.ObjectModel.ObservableCollection<meetpoint_b2c.servicereference1.suppcatalogue> EndGetProductData(System.IAsyncResult result) {
                object[] _args = new object[0];
                System.Collections.ObjectModel.ObservableCollection<meetpoint_b2c.servicereference1.suppcatalogue> _result = ((System.Collections.ObjectModel.ObservableCollection<meetpoint_b2c.servicereference1.suppcatalogue>)(base.EndInvoke("GetProductData", _args, result)));</meetpoint_b2c.servicereference1.suppcatalogue></meetpoint_b2c.servicereference1.suppcatalogue>
                return _result;
            }</meetpoint_b2c.servicereference1.suppcatalogue>
Posted
Updated 2-Jul-12 22:02pm
v2
Comments
hueikar 3-Jul-12 4:15am    
But it runs well before i insert one record..
After i insert one record then it show me this error..
But if i delete the only one record that i had insert it does not had error again..
hueikar 3-Jul-12 9:01am    
@amitgajjar Everything works fine b4 i add any data into sql server..
the error occur when i add data inside..

1 solution

This can happen when there is no end point configured at serverside.

OR

It can happen when the data that you send to server differ.

Try to make sure that the type of method parameter that you send to server is same as your contract.
If you try to send object[] instead of string[] such exception can happen.
 
Share this answer
 
v2
Comments
[no name] 3-Jul-12 6:23am    
Just make sure that the host is not down after you did the operation. Sometimes it happens that when there is any exception at service side, the host can go down and the subsequent request can fail.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900