I try to use ICS v6 TWSocket in async non-blocking mode.
(IDE C++Builder 2007)

I build little App for testing and benchmarks.

My app just send/receive data to server on second
PC conneceted via 1 GB LAN and show some statistic
on form.

And I have a problem: on heavy load (100+ TWSockets)
my test app responding to user actions very slowly
(about 10 sec delay for pressing buttons, repainting
labels etc) !

Usually I use Application->ProcessMessages in this case.

But with TWSocket - I can't because ProcessMessages
can be called only from some TWSocket events
(OnRequestDone, OnResponce, etc) !

But it's will produce many problems in async mode !

So, how I can repaint App interface and respond to user
actions ? Where to call Process Messages ?

Or maybe I forgot to set some important TWSocket property ?

Use a thread to put your communication stuff so that the main thread stay responsive for the user interface. Don't forget to create a message pump in your thread or no event will be handled. There are samples in the demos included with ICS. Don't forget to set multithread property to true.

The author of the freeware multi-tier middleware MidWare
The author of the freeware Internet Component Suite (ICS)

To unsubscribe or change your settings for TWSocket mailing list
please goto http://lists.elists.org/cgi-bin/mailman/listinfo/twsocket
Visit our website at http://www.overbyte.be

Reply via email to