Hi Jeff,
You can try the following code,
try
mydatabase.open
except
do something
on E: Exception do
showmessage(E.Message)
end
----- Original Message -----
From: "jeffgallant2002" <[EMAIL PROTECTED]>
To: <[email protected]>
Sent: Thursday, March 17, 2005 11:33 PM
Subject: [delphi-en] How do I trap a database exception message
>
>
> Delphi 6 - Oracle 9i Lite database
>
> I have a TDatabase object that seems to throw an exception when
> being opened in rare circumstances and never on the development
> system where the debugger would display the message. I'd like to
> trap the exception message in my code so I can work out why it is
> failing.
>
> My code is of the form
>
> try
> mydatabase.open
> except
> do something
> <this is where I'd like to trap the exception message>
> end
>
> I'm sure it is trivially easy but I can't find it in the manuals.
>
> Hope someone can help.
>
> Jeff
>
>
>
>
>
> -----------------------------------------------------
> Home page: http://groups.yahoo.com/group/delphi-en/
> To unsubscribe: [EMAIL PROTECTED]
> Yahoo! Groups Links
>
>
>
>
>
>
>
-----------------------------------------------------
Home page: http://groups.yahoo.com/group/delphi-en/
To unsubscribe: [EMAIL PROTECTED]
Yahoo! Groups Links
<*> To visit your group on the web, go to:
http://groups.yahoo.com/group/delphi-en/
<*> To unsubscribe from this group, send an email to:
[EMAIL PROTECTED]
<*> Your use of Yahoo! Groups is subject to:
http://docs.yahoo.com/info/terms/