Hello, my application creates a new thread by client connection and these threads communicate by custom Windows messages with others threads. Before, with ICS in the Execute() method i had:
//create the message queue MSG msg; PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE); PostThreadMessage(ThreadID,WM_NULL,0,0); WaitMessage(); //etc. socket->ProcessMessages(); //The quick message pump Now, in the Execute() method i think there should be something like this (extracted from this article http://bcbjournal.com/free_issue/Mar04-01.htm): //create the message queue MSG msg; PeekMessage(&msg, NULL, 0, 0, PM_NOREMOVE); PostThreadMessage(ThreadID,WM_NULL,0,0); WaitMessage(); // the message pump while (!Terminated && PeekMessage(&msg, NULL, 0, 0, PM_REMOVE)) { // break, if asked to quit if (msg.message == WM_QUIT) { Terminate(); break; } // for window-specific messages DispatchMessage(&msg); // for thread-specific messages switch (msg.message) { //message handlers } } Is this the correct method with ICS? I must overwrite MessagePump method or OnMessagePump event? Greetings Lorenzo -- To unsubscribe or change your settings for TWSocket mailing list please goto http://www.elists.org/mailman/listinfo/twsocket Visit our website at http://www.overbyte.be