PDA

Click to See Complete Forum and Search --> : Windows Socket Programming in C


hurgh
Jun 27th, 2002, 07:49 PM
Hi,

Just after any free eBooks, tutorials or any info on Network programming using c (console based), if anyone knows any good sites or links, and could paste them here, that would be a great help to me..

I can do Socket programming in Unix/Linux so i know a bit about it, and the code i write is normaly very portable, but i am not realy sure what headers i should include, so maybe even if you just gave me a list of the headers that i should include in my windows program that would be great..

Thanks for the help..


-|- Hurgh -|-

abdul
Jun 27th, 2002, 08:58 PM
Just include

Ws2_32.lib

in your Linker parameter. If you include "windows.h", then the latest header file for winsock will automatically be declared so you don't need anything else.
Almost everything is same for winsock on UNIX and Windows but Windows has implemented some additional features in Winsock 2.2. They start with WSA and can also support advanced non-blocking mode. I think the original Winsock only has "select" function to implement non-blocking mode but Winsock got 2 more that you can play around with while programming using Windows.
Here's a good tutorial to get your started:
http://www.inf.pucrs.br/~derose/files/winsocktutorial.html

hurgh
Jun 28th, 2002, 02:12 AM
Thanks for the reply, that is what i wanted, and it will help me out a lot..

Thanks again,

-|- Hurgh -|-