I am doing a chat in C# and I got this error:
System.ServiceModel.EndpointNotFoundException: Could not connect to http://localhost:9000/MyService. TCP error code 10061: No connection could be made because the target machine actively refused it 127.0.0.1:9000
Here is the config file of the server :
<?xml version="1.0" encoding="utf-8" ?><configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<system.serviceModel>
<services>
<service name="ChattingServer.ChattingService">
<endpoint address="net.tcp://localhost:9000/MyService"
binding="netTcpBinding" bindingConfiguration="" name="ChattingServiceEndPoint"
contract="ChattingInterfaces.IChattingService" />
</service>
</services>
</system.serviceModel>
And here is for the client side:
<?xml version="1.0" encoding="utf-8" ?><configuration>
<startup>
<supportedRuntime version="v4.0" sku=".NETFramework,Version=v4.5" />
</startup>
<system.serviceModel>
<client>
<endpoint address="net.tcp://localhost:9000/MyService"
binding="netTcpBinding" bindingConfiguration="" contract="ChattingInterfaces.IChattingService"
name="ChattingServiceEndPoint" kind="" endpointConfiguration="" />
</client>
</system.serviceModel>
I tried to fix it by activating the net.tcpListenerAdapter(Start->Service) but nothing happened. Thank you.