Click here to Skip to main content
15,886,873 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
I am trying to add WCF service Reference to classlibrary using svcutil.exe

My WCF Service is hosted in Windows Application Form.

The following is the error i am getting:

Quote:
Could not find default endpoint element that references contract 'IData' in the ServiceModel client configuration section. This might be because no configuration file was found for your application, or because no endpoint element matching this contract could be found in the client element.


Here is my App.config file:

HTML
<system.serviceModel>
      <bindings>
        <netTcpBinding>
          <binding name="NetTcpBinding_IData">
            <reliableSession inactivityTimeout="01:00:00" enabled="true" />
          </binding>
        </netTcpBinding>
      </bindings>
      <client>
        <endpoint address="net.tcp://localhost:8182/" binding="netTcpBinding"
            bindingConfiguration="NetTcpBinding_IData" contract="IData"
            name="NetTcpBinding_IData">
          <identity>
            <userPrincipalName value="xxx@xxx.com" />
          </identity>
        </endpoint>
      </client>
    </system.serviceModel>


What I have tried:

please suggest me how to solve this issue.
Posted
Updated 7-Jun-16 0:37am

1 solution

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