CObArray::ElementAt

CObject*&ElementAt(intnIndex**);**

Return Value

A reference to a CObject pointer.

Parameters

nIndex

An integer index that is greater than or equal to 0 and less than or equal to the value returned by GetUpperBound.

Remarks

Returns a temporary reference to the element pointer within the array. It is used to implement the left-side assignment operator for arrays. Note that this is an advanced function that should be used only to implement special array operators.

The following table shows other member functions that are similar to CObArray::ElementAt.

Class Member Function
CByteArray BYTE& ElementAt( int nIndex);
CDWordArray DWORD& ElementAt( int nIndex);
CPtrArray void*& ElementAt( int nIndex);
CStringArray CString& ElementAt( int nIndex);
CUIntArray UINT& ElementAt( int nIndex);
CWordArray WORD& ElementAt( int nIndex);

Example

See the example for CObArray::GetSize.

CObArray OverviewClass MembersHierarchy Chart

See Also   CObArray::operator []