Click here to Skip to main content
15,887,596 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi..
when i invoking wcf service i am getting error as

Failed to invoke the service. Possible causes: The service is offline or inaccessible; the client-side configuration does not match the proxy; the existing proxy is invalid. Refer to the stack trace for more detail. You can try to recover by starting a new proxy, restoring to default configuration, or refreshing the service.

hee i have posted my service and client configuration.

server config:

XML
<system.serviceModel>
   <bindings>
     <basicHttpBinding>
       <binding name="BasicHttpBinding_IFileTransfer" />
     </basicHttpBinding>
   </bindings>
   <client>
     <endpoint address="http://localhost:51783/FileTransfer.svc" binding="basicHttpBinding"
       bindingConfiguration="BasicHttpBinding_IFileTransfer" contract="ServiceReference1.IFileTransfer"
       name="BasicHttpBinding_IFileTransfer" />
   </client>
   <services>
     <service name="LeapServer.Service1">
       <endpoint address="" binding="basicHttpBinding" contract="LeapServer.IService1">
         <identity>
           <dns value="localhost" />
         </identity>
       </endpoint>
       <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
       <host>
         <baseAddresses>
           <add baseAddress="http://localhost:8732/Design_Time_Addresses/LeapServer/Service1/" />
         </baseAddresses>
       </host>
     </service>
   </services>
   <behaviors>
     <serviceBehaviors>
       <behavior>
         <serviceMetadata httpGetEnabled="True"/>
         <serviceDebug includeExceptionDetailInFaults="False" />
       </behavior>
     </serviceBehaviors>
   </behaviors>
 </system.serviceModel>


client config
XML
<system.serviceModel>
    <bindings />
    <client />
    <services>
      <service name="LeapClient.FileTransfer">
        <endpoint address="" binding="wsHttpBinding" contract="LeapClient.IFileTransfer">
          <identity>
            <dns value="localhost" />
          </identity>
        </endpoint>
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
        <host>
          <baseAddresses>
            <add baseAddress="http://localhost:8732/Design_Time_Addresses/TestLeapClient1/Clientservice1/" /> 
          </baseAddresses>
        </host>
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="MyServiceTypeBehaviors" >
          <serviceMetadata httpGetEnabled="true" />
          <serviceDebug includeExceptionDetailInFaults="False" />
        </behavior>
      </serviceBehaviors>
    </behaviors>

  </system.serviceModel>


can anyone suggest me to resolve this issue?

What I have tried:

i have tried as error said to add new proxy and updating service reference still it not working..
Posted

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

  Print Answers RSS
Top Experts
Last 24hrsThis month


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