Hello Coders, i code on a submit engine and like to know if the submit was succesfull or not . example: i connect to google.de and send my infos : url to submit,email and language of homepage. how do i know if the submit is succesfull or not ? i use : call htons ,80 ; HTTP-Service mov ,AF_INET mov ,ax call inet_addr ,offset Submit_IP_01 ; the ip to google cmp eax ,SOCKET_ERROR jz Error_IP this works fine if the ip has changed ,but how can i get the error from this ? call send ,conn_socket ,offset buff ,eax ,0 cmp eax ,SOCKET_ERROR ;-- what error message must i insert here if the submit fails ??? jz Error_Submit_01 thanks ;) ps: http://blake.prohosting.com/easycode/ for a little beta
Posted on 2001-05-25 05:41:00 by EasyCode
after you get SOCKET_ERROR value, call WSAGetLastError immediately to retrieve the actual error code. You can then look up the error in windows.inc. The winsock error codes are the ones with the names starting with "WSAE"
Posted on 2001-05-26 04:31:00 by Iczelion
Hello Coder, thanks a lot for the answer :-) i use now : .if eax==SOCKET_ERROR call WSAGetLastError .if eax!=WSAEWOULDBLOCK call lstrcpy,offset errordummy,offset d01 call MessageBox,0,offset errordummy,offset errortitle,0 .endif .endif and it works fine. i post the next days the src. for the url submit engine ,without the help from here im shure i cant code one :-) thx
Posted on 2001-05-27 04:47:00 by EasyCode