Yes, that's the better method, but you stated that you wish to use the before method, and I prefer to respect ppl. wishes ;-) Anyway, this is much better what you do now, the messaging part (window) is useful only when you have to handle the winsock 1. Only disadvantage is that you have two threads - mean the whole design is more complicated due to resource locking etc. I usualy trying to design it that it uses only one thread for all that tasks. But it really depends on the application, so there cannot be a general advice except that I said. wish you good luck!