Class ODBCErrors (Excel VBA)
A collection of ODBCError objects. To use a ODBCErrors class variable it first needs to be instantiated, for example
Dim odbs as ODBCErrors
Set odbs = Application.ODBCErrors
For Each
Here is an example of processing the ODBCErrors items in a collection.
Dim odber As ODBCError
For Each odber In Application.ODBCErrors
Next odber
Count
Returns a Long value that represents the number of objects in the collection.
Dim lngCount As Long
lngCount = Application.ODBCErrors.Count
Item
Returns a single object from a collection.
Item (Index)
Index: The index number for the object.