Hi All,
I am trying to make a simple application using CAsyncSocket derived class.However, I seem to get stuck at the following points:
1.The Connect function always returns FALSE in SOCK_STREAM mode.The GetLastError() function shows the error as WSAEWOULDBLOCK.I also have a OnConnect handler in my class.However, it is never called.What is happening here?
2.When the Connect function is called for a Socket created with SOCK_DGRAM,the function fails and GetLastError() returns WSAEHOSTUNREACH.
3.The IP Address and Port Number are valid since another application using the same IP and port number executes smoothly.However that uses Windows SOCKET instead of CAsyncSocket class.
Any one having any idea please help me as I am at the end of my project deadline.Any sample application on CAsyncSocket for study is also welcome.
Thanking in Advance,
ss2905
I am trying to make a simple application using CAsyncSocket derived class.However, I seem to get stuck at the following points:
1.The Connect function always returns FALSE in SOCK_STREAM mode.The GetLastError() function shows the error as WSAEWOULDBLOCK.I also have a OnConnect handler in my class.However, it is never called.What is happening here?
2.When the Connect function is called for a Socket created with SOCK_DGRAM,the function fails and GetLastError() returns WSAEHOSTUNREACH.
3.The IP Address and Port Number are valid since another application using the same IP and port number executes smoothly.However that uses Windows SOCKET instead of CAsyncSocket class.
Any one having any idea please help me as I am at the end of my project deadline.Any sample application on CAsyncSocket for study is also welcome.
Thanking in Advance,
ss2905