Hi everybody, I am Tanmoy. I just wanna create a simple server-client chat application in C#. I have downloaded the source code from the link below:
http://www.codeguru.com/csharp/csharp/cs_network/sockets/article.php/c7695

If the server & client both in same PC everything is OK.
But if the client application tries to establish a connection to a the server application on a remote PC it fails to do so.

A messagebox show the following message:

A connection attemp failed because the connected party did not properly respond after a period of time or established connection failed because connected host has failed to respond 172.16.10.40:8000

what can I do? Please help me.

Check theres no firewalls on either machine, and see if you can connect using the built in telnet (unless its vista which doesnt bother to install it by default) , if you can connect with telnet but not the app, somethings not quite right, if you cant connect with telnet, check the server end is listening on the IP you think and not just listening on 127.0.0.1

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.