Wow, my application really works much better after deleting all application
processmessages on my code...

On 2/20/06, Francois Piette <[EMAIL PROTECTED]> wrote:
>
> > so I can't call application.processmessages at all?
>
> Sure you can, but not from an event handler or you'll have problem
> reentering events. You have the
> same problem with a simple button: in the button OnClick, program a loop
> calling ProcessMessage
> during 30 seconds. You'll see that during this period the user can click
> again on the button and
> your event handler is reentered, causing a lot of trouble to the code you
> have in the handler. You
> can solve this problem by disabling the button while processing and
> calling the message pump. But
> speaking network, you can't [easily, without knowning exactly what you are
> doing] disable packet
> transmission and so your event handlers are re-entered, causing a lot of
> trouble in the component
> (you receive the same data twice for example).
>
> > what can I call if I need my user interface updated? for example I
> changed a
> > Label's caption and need it refreshed when accepting data?
>
> You don't need to call ProcessMessages for that purpose, specially with a
> non blocking component
> like ICS. Just change caption, nothing more, nothing less.
>
>
> --
> Contribute to the SSL Effort. Visit
> http://www.overbyte.be/eng/ssl.html
> --
> [EMAIL PROTECTED]
> Author of ICS (Internet Component Suite, freeware)
> Author of MidWare (Multi-tier framework, freeware)
> http://www.overbyte.be
>
>
> --
> 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
>
-- 
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

Reply via email to