this Socket.listen works, but it also locks up - completely.
is there any way to make something raise an event that would come when 'listen' would have ended?
(probably, but how?)
[C#] raise event at incomming connection?
Moderator: MaxCoderz Staff
-
- Calc King
- Posts: 1513
- Joined: Sat 05 Aug, 2006 7:22 am
- benryves
- Maxcoderz Staff
- Posts: 3089
- Joined: Thu 16 Dec, 2004 10:06 pm
- Location: Croydon, England
- Contact:
It sounds like you need to implement an asynchronous client/server design rather than a synchronous one.
Socket Code Examples.
Socket Code Examples.
...The client is built with an asynchronous socket, so execution of the client application is not suspended while the server returns a response. ...
...The server is built with an asynchronous socket, so execution of the server application is not suspended while it waits for a connection from a client. ...
-
- Calc King
- Posts: 1513
- Joined: Sat 05 Aug, 2006 7:22 am
- benryves
- Maxcoderz Staff
- Posts: 3089
- Joined: Thu 16 Dec, 2004 10:06 pm
- Location: Croydon, England
- Contact:
Incidentally, I thought you were looking to raise your own events within a class before reading your post. For that, this walkthrough has been useful to me.
-
- Calc King
- Posts: 1513
- Joined: Sat 05 Aug, 2006 7:22 am
-
- Calc King
- Posts: 1513
- Joined: Sat 05 Aug, 2006 7:22 am