| title | ADO Error Codes | |
|---|---|---|
| description | Capture ADO Error Codes | |
| author | rothja | |
| ms.author | jroth | |
| ms.date | 02/15/2017 | |
| ms.service | sql | |
| ms.subservice | ado | |
| ms.topic | conceptual | |
| helpviewer_keywords |
|
In addition to the provider errors returned in the Error objects of the Errors collection, ADO itself can return errors to the exception-handling mechanism of your run-time environment. Use the error trapping mechanism your programming language, such as the On Error statement in Microsoft® Visual Basic, or the try-catch block in Microsoft Visual C++®, to capture ADO errors.
For the list of ADO error codes, see ErrorValueEnum.