DetailsViewRowCollection::GetEnumerator Method ()
Returns an enumerator that contains all DetailsViewRow objects in the DetailsViewRowCollection object.
Assembly: System.Web (in System.Web.dll)
Return Value
Type: System.Collections::IEnumerator^An IEnumerator-implemented object that contains all DetailsViewRow objects in the DetailsViewRowCollection.
Implements
IEnumerable::GetEnumerator()Use this method to get an enumerator that can be iterated through linearly to access each item in the DetailsViewRowCollection object. To access the item at the current position in the enumerator, use the Current property. Use the MoveNext method to move to the next item in the collection. To move the enumerator to its initial position, use the Reset method.
The following code example demonstrates how to use the GetEnumerator method to retrieve an enumerator that contains the items from the collection. The enumerator is then iterated through and the value of each row is displayed on the page.
Available since 2.0
