NGWS SDK Documentation  

This is preliminary documentation and subject to change.
To comment on this topic, please send us email at ngwssdk@microsoft.com. Thanks!

IEnumerator.MoveNext

When implemented by a class, advances the enumerator to the next element of the collection.

[Visual Basic]
Function MoveNext() As Boolean
[C#]
bool MoveNext();
[C++]
bool MoveNext() = 0;
[JScript]
function MoveNext() : Boolean;

Return Value

true if the enumerator was successfully advanced to the next element.

false if the enumerator has passed the end of the collection.

Exceptions

Exception Type Condition
InvalidOperationException The collection was modified after the enumerator was instantiated.

Remarks

After an enumerator is created or after a Reset, an enumerator is conceptually positioned before the first element of the collection, and the first call to MoveNext moves the enumerator over the first element of the collection.

If elements are added, removed or repositioned in the collection after this enumerator was created, MoveNext may throw an exception.

Once the end of the collection is passed, subsequent calls to MoveNext will return false until Reset is called.

See Also

IEnumerator Interface | IEnumerator Members | System.Collections Namespace | Current | Reset