IIterator<T>.HasCurrent Property
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Gets a value that indicates whether the iterator refers to a current item or is at the end of the collection.
public:
property bool HasCurrent { bool get(); };
bool HasCurrent();
public bool HasCurrent { get; }
Public ReadOnly Property HasCurrent As Boolean
Property Value
bool
True if the iterator refers to a valid item in the collection; otherwise, false.
Remarks
If the underlying collection has changed, the iterator may throw an exception.
.NET Framework If the underlying collection has changed, the iterator may throw a
COMException
exception with an HResult of0x8000000C
(E_CHANGED_STATE
).
C++/WinRT If the underlying collection has changed, the iterator may throw a
hresult_changed_state
exception.
C++/CX If the underlying collection has changed, the iterator may throw a
ChangedStateException
exception.