BorlandTalk.com Forum Index BorlandTalk.com
Borland discussion newsgroups
 
Archives   FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

How to trap exception message text without allowing raise

 
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi ObjectPascal
View previous topic :: View next topic  
Author Message
Guest






PostPosted: Wed Feb 07, 2007 9:04 pm    Post subject: How to trap exception message text without allowing raise Reply with quote



I'm working with some open-source delphi code that provides access to
database via ODBC. My Delphi app is a CGI program running in console
mode. It's working well, but there's something I'd like to be able to
do that so far eludes me.

The open-source delphi code is well-written, with exception-trapping,
etc. If we try to execute an SQL statement that contains some sort of
error, the exception raised displays the SQL error in the output
stream, and it appears in the web browser that's accessing my
program. However, the raised exception also stops execution of
my .exe, so the program is not able to gracefully handle SQL statement
errors.

I've altered the open source code to be able to turn off exceptions,
but so far have been unable to determine how to find the SQL error
message text that the exception was displaying.

I'll post some code if that would help better explain the problem -
please let me know....
..
Mark
Back to top
Guest






PostPosted: Thu Feb 08, 2007 8:10 pm    Post subject: Re: How to trap exception message text without allowing rais Reply with quote



Please disregard, solved it myself.....the error object contains a
Message field, the SQL error was found in it.....
Back to top
Display posts from previous:   
Post new topic   Reply to topic    BorlandTalk.com Forum Index -> Delphi ObjectPascal All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2006 phpBB Group
SEO toolkit © 2004-2006 webmedic.