Share via


XRValueCollectionT.IndexOf(const ItemType&,int *) (Compact 2013)

3/28/2014

This method determines the index of the specified item in the collection.

Syntax

HRESULT IndexOf(
const ItemType & Value,
int * pIndex)

Parameters

  • Value
    [in] A pointer to the item of type ItemType to find in the collection.
  • pIndex
    [out] The indexed position of the item, if it was found in the collection; otherwise, -1.

Return Value

The following table shows the possible return values.

Value

Description

S_OK

The method was successful.

E_FAIL

The method was unsuccessful.

E_POINTER

The Value or pIndex parameter is not valid.

Remarks

ItemType is defined in the ItemType template parameter of the XRValueCollectionT<IFace,ItemType> class.

Requirements

Header

XRCollection.h

See Also

Reference

XRValueCollectionT<IFace,ItemType>