Can I run a Sockets program on a Windows machine that's not connected to a network?

Brian O'Byrne

Yes, as long as TCP/IP is installed on the machine in some way.

If you have TCP/IP installed on any interface, e.g. the local loopback interface or a dialup interface, you can expect all socket operations to succeed as long as you are communicating only with yourself. You may use "localhost" as the hostname or as the IP address.

If you do not have any TCP/IP networking installed, you can expect socket operations to throw exceptions such as BindException, ConnectException, ProtocolException, SocketException, etc.

0 Comments  (click to add your comment)
Comment and Contribute






(Maximum characters: 1200). You have 1200 characters left.



About | Sitemap | Contact