Re: Indy 9 based app simply terminates...

Giganews Newsgroups
Subject: Re: Indy 9 based app simply terminates...
Posted by:  Remy Lebeau (TeamB) (
Date: Mon, 29 Nov 2004

"nd" <> wrote in message

> Works very well most of the time, but sometimes the app
> simply terminates and disappears without a trace?! No
> error messages, nothing. Doesn't seem to be under
> particularly heavy load either. Any suggestions?

Sounds like an uncaught exception is probably terminating the main thread.

> Was thinking of syncronizing issues with the GUI or filesystem.
> I'm doing this with Enter/LeaveCriticalSection - is this appropriate?

You cannot use a critical section to sync access to the GUI.  You must use
the TThread.Synchronize() method, or a TIdSync descendant class, or custom
thread messages, etc.  GUI operations need to be performed in the context of
the main thread only.




In response to

Indy 9 based app simply terminates... posted by nd on Mon, 29 Nov 2004