CogDatabaseDirectory GetEnumerator Method Cognex VisionPro 9.24
Create a strongly typed enumerator to facilitate iterating through the items in this database. Note that enumerators are fragile - externally adding or removing items from this database will invalidate the enumerator. Also note that modifying an ICogRecord returned by (the Current property of) this enumerator will have absolutely no affect on the database since it is a freshly created copy of the database item, just as with the Fetch method.

Namespace: Cognex.VisionPro.Database
Assembly: Cognex.VisionPro.Database (in Cognex.VisionPro.Database.dll) Version: 91.0.0.0 (91.0.0.0)
Syntax

public IEnumerator<ICogRecord> GetEnumerator()

Return Value

Type: IEnumerator ICogRecord 
An enumerator whose Current property is of type ICogRecord.

Implements

IEnumerable T  GetEnumerator 
Exceptions

ExceptionCondition
ObjectDisposedException Thrown if this object has already been disposed.
InvalidOperationException Thrown if not currently connected.
See Also