The first thing you have to know is the protocol the server uses. If it's a common one like HTTP you can use an off the shelf library e.g.
wininet[
^] or
libcurl[
^] to do the business for you.
If it's a proprietary protocol or one you specify then you're going to have to get a bit further down. There is a general API for networking: sockets and the windows implementation of sockets over TCP/IP is in WINSOCK.DLL.
While it won't show you how to program the sockets interface
"Internetworking with TCP/IP: Principles, protocols, and architecture" by Douglas Comer will tell you all you want to know about the underlying TCP/IP protocols.
Unfortunately I've yet to find a
really good book on sockets programming for windows
. This[
^] is an okay reference to the API itself. Hopefully someone else can give you a decent reference to a resource they've used. I haven't seen any I'd regard as more than mediocre so it'd be better if you did your own research here. If no-one else can give you a reference I'd search for "Windows sockets programming" and take it from there.