Interface

# Iterator

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

## Description

Iterators perform the actual task of yielding values from the Iterable object.

## Methods

<div class="rst-class">

table-centered_column_4

</div>

| Name                          | Parameters | Returns                            | Shared |
|-------------------------------|------------|------------------------------------|--------|
| `MoveNext<iterator.movenext>` |            | `Boolean</api/data_types/boolean>` |        |
| `Value<iterator.value>`       |            | `Variant</api/data_types/variant>` |        |

## Method descriptions

<div id="iterator.movenext">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

Iterator.MoveNext

**MoveNext** As `Boolean</api/data_types/boolean>`

> Moves the <span class="title-ref">Iterator</span> to the next item.
>
> Return False when there are no more items, otherwise return `True</api/language/true>`.

<div id="iterator.value">

---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------

</div>

<div class="rst-class">

forsearch

</div>

Iterator.Value

**Value** As `Variant</api/data_types/variant>`

> The value of the current item in the <span class="title-ref">Iterator</span>. The Value is invalid when MoveNext returns `False</api/language/false>`. It is also invalid before the first call to MoveNext.
>
> Return the value of the current item in the <span class="title-ref">Iterator</span>.

## Compatibility

|                       |     |
|-----------------------|-----|
| **Project Types**     | All |
| **Operating Systems** | All |

<div class="seealso">

`Iterable</api/language/iterable>` interface

</div>
