Kristofer Skaug
Re: Exceptions vs Error codes

Re: Exceptions vs Error codes

In article <3b7d7eac_2@dnews>
	"Kristofer Skaug" <✉> wrote:

> "Barry Kelly" <✉> wrote in message
> news:✉
> > There is a try..except that protects the TThread.Execute method; before
> > the application would just fall off a cliff, unless you had your own
> > one
> > in .Execute.
> Ah, interesting! so does TThread have an OnException/OnError event as
> well?
> Or how do you hook into that exception handler?

You don't. It just terminates the thread.

> <snip>
> > This rare case is the only one for which an *individual* try..except
> > block is warranted.
> >
> > The others can get along with a bed-rock mechanism.
> Again, this is a matter of application error handling strategy: "If you
> don't care where you are, you ain't lost".
> Kristofer

You should attach a string to a fixed object, and make sure you're able
to follow it back should you get lost; only cut it if you make it

That is, program using a transactional paradigm.
-- Barry
FYI: Phrase searches are enclosed in either single or double quotes
Originally created by
Tamarack Associates
Tue, 07 Feb 2023 04:30:33 UTC
Copyright © 2009-2023
HREF Tools Corp.