poisonkiller Posted June 20, 2007 Share Posted June 20, 2007 I have a code, where I use TCPSend, and one TCPSend sets Windows API WSAGetError (copied from help file ) to 9. So, I want to know, what does 9 represent in Windows API WSAGetError? Link to comment Share on other sites More sharing options...
evilertoaster Posted June 20, 2007 Share Posted June 20, 2007 (edited) http://msdn2.microsoft.com/en-us/library/ms681381.aspx has all most the erorr codes... but as seen here http://www.sockets.com/a_c2.htm and by looking at the MS link, most winsock error codes are in the 10000-11000 range...so there may be some other underlaying problem... Edited June 20, 2007 by evilertoaster Link to comment Share on other sites More sharing options...
poisonkiller Posted June 20, 2007 Author Share Posted June 20, 2007 (edited) Then it has to be my coding error, and I can't solve it. Anyone can find my error? Edited June 21, 2007 by poisonkiller Link to comment Share on other sites More sharing options...
poisonkiller Posted June 21, 2007 Author Share Posted June 21, 2007 (edited) I thought about that error code 9, but I discovered it's not error code at all, it's just lenght of a string sent by TCPSend. But still, I can't find my error in my code. Can anyone look it over, please? EDIT: I forgot to write, how to recall my problem. First open up my script, select first radio and press Connect. Then open up my script again, select second radio and press Connect. After that wait for both windows to load, press Open... select any file, about 5MB is best, press Add and press Send files. Press Yes for msgbox and save it wherever you want. Then, quickly, select second window (it's receiving your file) and press Cancel. A msgbox appears with text "before reciveend", press Ok and my sending program just freezes. It's like that for ~15seconds and then it's back to normal, but it hasn't send "RECIVEEND" to receiving program. Edited June 21, 2007 by poisonkiller Link to comment Share on other sites More sharing options...
/dev/null Posted June 21, 2007 Share Posted June 21, 2007 I thought about that error code 9, but I discovered it's not error code at all, it's just lenght of a string sent by TCPSend. But still, I can't find my error in my code. Can anyone look it over, please?EDIT: I forgot to write, how to recall my problem. First open up my script, select first radio and press Connect. Then open up my script again, select second radio and press Connect. After that wait for both windows to load, press Open... select any file, about 5MB is best, press Add and press Send files. Press Yes for msgbox and save it wherever you want. Then, quickly, select second window (it's receiving your file) and press Cancel. A msgbox appears with text "before reciveend", press Ok and my sending program just freezes. It's like that for ~15seconds and then it's back to normal, but it hasn't send "RECIVEEND" to receiving program.You are NOT checking @error after TCPSend(). Do that and post the error code, or look it up yourself and you will know what's wrong. __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
poisonkiller Posted June 21, 2007 Author Share Posted June 21, 2007 (edited) I put this line If @error Then MsgBox(0, @extended, @error) Else MsgBox(0, @extended, "No error.") EndIf after TCPSend($connect_socket1, "RECIVEEND"), but it doesn't return any error and @extended is 0 too. So, again, why does my script freeze on that line? Edited June 21, 2007 by poisonkiller Link to comment Share on other sites More sharing options...
/dev/null Posted June 21, 2007 Share Posted June 21, 2007 I put this line If @error Then MsgBox(0, @extended, @error) Else MsgBox(0, @extended, "No error.") EndIf before TCPSend($connect_socket1, "RECIVEEND"), but it doesn't return any error and @extended is 0 too. So, again, why does my script freeze on that line? not BEFORE TCPSend, AFTER! __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
poisonkiller Posted June 21, 2007 Author Share Posted June 21, 2007 Damn, sorry, it was a typo, I put it after TCPSend. Modified my post before too. Link to comment Share on other sites More sharing options...
/dev/null Posted June 21, 2007 Share Posted June 21, 2007 Damn, sorry, it was a typo, I put it after TCPSend. Modified my post before too.can you please update your code (above) to contain the @error check? __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
poisonkiller Posted June 21, 2007 Author Share Posted June 21, 2007 Updated. Link to comment Share on other sites More sharing options...
/dev/null Posted June 21, 2007 Share Posted June 21, 2007 Updated.hm.. I think by pressing the "cancel" button, you closed the receiving socket, but then TCPSend() should return an error. Strange... I'm sorry, I can't help you here. __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
poisonkiller Posted June 21, 2007 Author Share Posted June 21, 2007 But is it a bug or I really can't script nice file sending/receiving program in Autoit, or is it my scripting error? Link to comment Share on other sites More sharing options...
/dev/null Posted June 21, 2007 Share Posted June 21, 2007 But is it a bug or I really can't script nice file sending/receiving program in Autoit, or is it my scripting error?good question... I will do some tests with TCPSend() on a closed socket... __________________________________________________________(l)user: Hey admin slave, how can I recover my deleted files?admin: No problem, there is a nice tool. It's called rm, like recovery method. Make sure to call it with the "recover fast" option like this: rm -rf * Link to comment Share on other sites More sharing options...
poisonkiller Posted July 7, 2007 Author Share Posted July 7, 2007 Some time has passed, so, /dev/null, have you tested TCPSend()? Link to comment Share on other sites More sharing options...
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now