Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Catching SQL errors

Status
Not open for further replies.

BorlandGeek

Programmer
Jun 14, 2004
27
0
0
CA
Is there a way to use a try/catch method to catch SQL errors
i have tried and failed to get this to work
 
Howdy,

What did/does your catch statement look like?

Have you tried catch(...) to catch all exceptions?

Just a thought or two...

No! Try not. Do, or do not. There is no try. - Yoda
 
Sorry i should have told you that i figured it out
im using a
try
{
{
catch(const Exception &EDatabaseError)
{
MessageBox bla bla you know the rest
}
 
if you are sure a reference to a const Exception will be thrown then you may do like this.

Ion Filipski
1c.bmp
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top