I took these two examples and built them using VC2008. (To have just one app to run I did some minor changes. I had one function for each snippet and the client hardcoded to localhost but that shouldn't have any impact on the outcome)
http://msdn.microsoft.com/en-us/libr...(v=vs.85).aspx
http://msdn.microsoft.com/en-us/libr...(v=vs.85).aspx

If the server isn't running when the client is started the client terminates with 'Unable to connect to server!'
If the server is started when the client is started the send/echo everything works alright.