Author | Message | Time |
---|---|---|
iGotPropz | Hi, I am also coding a C# bot, have been going for about 2 weeks, then I found an old copy of Myndfyre's connect stashed way in the back of the forums, and modified it to my style (but it has his backbone structure). It compiles fine, but when I execute it to connect... ( I am using BeginConnect(), EndConnect() IAsyncResult systems) This error occurs after I initiate the Connect(), and it leads off onto sock_Connected(IAsyncResult ar) [code]System.Net.Sockets.SocketException: Unknown error (0x274d) at System.Net.Sockets.Socket.EndConnect(IAsyncResult asyncResult) at JediOps.JediForm.sock_Connected(IAsyncResult ar) in c:\My Documents\SharpDevelop Projects\Battle.net Bot\MainForm.cs:line 470 [/code] Now I'm assuming it have to be with the s.BeginConnect(); AsyncCallBack mismatching with the s.EndConnect();. If you might happen to know why this occurs off hand, could you please tell me? Or if you would like to see the source code of those two, I'd be glad to show you and get your input. Much thanks, -Matt/iGotPropz | August 22, 2004, 6:41 PM |
Myndfyr | I find the mismatching analysis highly unlikely. When you call EndConnect(), you specify an IAsyncResult parameter. EncConnect compares the IAsyncResult with the one you get from calling BeginConnect() (it does this in case you just want to set up a thread for polling), and if they don't match, the message of the SocketException will actually say that they're mismatched. Beyond that, I really can't help you. Like it says, "Unknown error." :/ Oh, and when using [ code ] [ /code ] tags, use lowercase. ;) | August 22, 2004, 6:46 PM |
iGotPropz | Ok thanks, and thanks about the code thing, used to always typing my HTML in caps, so i did also for the code | August 22, 2004, 7:50 PM |
Myndfyr | [quote author=iGotPropz link=board=17;threadid=8316;start=0#msg76851 date=1093204209] Ok thanks, and thanks about the code thing, used to always typing my HTML in caps, so i did also for the code [/quote] HTML in all caps? Bad! Go XHTML! All lowercase!!! :P | August 23, 2004, 12:01 AM |