The Errors collection contains all stored Error objects, all of which pertain to a single operation involving ADO.
Any operation involving ADO objects can generate one or more errors. As each error occurs, one or more Error objects may be placed in the Errors collection of the Connection object. When another ADO operation generates an error, the Errors collection is cleared, and the new set of Error objects may be placed in the Errors collection. ADO operations that don't generate an error have no effect on the Errors collection. Use the Clear method to manually clear the Errors collection.
The set of Error objects in the Errors collection describes one error. Enumerating the specific errors in the Errors collection enables your error-handling routines to more precisely determine the cause and origin of an error, and take appropriate steps to recover.
Some properties and methods return warnings that appear as Error objects in the Errors collection but do not halt a program's execution. Before you call the Delete, Resync, UpdateBatch, or CancelBatch methods on a Recordset object, or before you set the Filter property on a Recordset object, call the Clear method on the Errors collection so that you can read the Count property of the Errors collection to test for returned warnings.
To refer to an Error object in a collection by its ordinal number, use either of the following syntax forms:
connection.Errors.Item(0)
connection.Errors(0)
Note See the Error object topic for a more detailed explanation of the way a single ADO operation can generate multiple errors.
file: /Techref/language/asp/comp/dadobj02.htm, 3KB, , updated: 1996/11/21 18:01, local time: 2024/12/1 16:14,
3.147.65.111:LOG IN
|
©2024 These pages are served without commercial sponsorship. (No popup ads, etc...).Bandwidth abuse increases hosting cost forcing sponsorship or shutdown. This server aggressively defends against automated copying for any reason including offline viewing, duplication, etc... Please respect this requirement and DO NOT RIP THIS SITE. Questions? <A HREF="http://massmind.org/Techref/language/asp/comp/dadobj02.htm"> Errors Collection (ADO)</A> |
Did you find what you needed? |
Welcome to massmind.org! |
Welcome to massmind.org! |
.