Iterates over the messages in an AllMessages collection, successively returning each message. Multiple AllMessagesIterator objects can be simultaneously active over the same collection. Each iterator maintains its own internal position and does not affect the state of the collection it is iterating.
Creates another, independent AllMessagesIterator object. The clone starts at the original object’s current position in the collection. Use Clone() to save the current position before a Skip or Reset.
Returns the next message in the collection or nothing after the last message.
Resets an iterator so that Next returns the first message in the collection.
Skips the next NumMessages messages. Skip does nothing if there are not NumMessages messages left to skip, or if NumMessages < 0.
Both AllMessagesIterator and IEnumVARIANT (from the AllMessages collection _NewEnum method) allow iterating an AllMessages collection. However, AllMessagesIterator is an object available in all object-oriented development environments, while IEnumVARIANT is a COM interface inaccessible in environments such as Delphi. The usual alternative to IEnumVARIANT is:
for i:= 1 to Count
This does not work with large collections, such as AllMessages, which do not support Count or Item.
The AllMessagesIterator object does not support a Refresh method.