Code: //#include"stdafx.h" #include<windows.h> #include<winsock.h> #include<stdio.h> #include<windows.h> int APIENTRY WinMain(HINSTANCE hlnstance,HINSTANCE hprevlnstance,LPSTR lpCmdLine,int nCmdShow) { WSADATA ws; char buf[1000],buf1[100],buf2[100],buf3[100],buf4[100],buf5[100],buf6[100]; WSAStartup(0x0101,&ws); // buf[0]=" "; sprintf(buf1,"\nWinsock Ver Request: %d.%d",HIBYTE(ws.wVersion),LOBYTE(ws.wVersion)); sprintf(buf2,"\nWinsock Ver Avilable: %d.%d",HIBYTE(ws.wHighVersion),LOBYTE(ws.wHighVersion)); sprintf(buf3,"\nCurrent Winsock imlementation: %s",&ws.szDescription); sprintf(buf4,"\nSystem status: %s",&ws.szSystemStatus); sprintf(buf5,"\nMaximum Socket: %u",&ws.iMaxSockets); strcat(strcat(strcat(strcat(strcat(strcat(buf,buf1),buf2),buf3),buf4),buf5),buf6); MessageBox(0,buf,"info",0); WSACleanup(); return 0; } i am using windows7 and dev c compiler bt this prog is not compiling please help me this prog is just to make socket
"not compiling" is no help at all. It gives us no clue what might be wrong. What errors do you get? Copy and paste the top five *exactly* and this might help.