Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining


Sets the array element at the specified index.

void SetAt( 
   INT_PTR nIndex, 
   ARG_TYPE newElement  


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


Template parameter specifying the type of arguments used for referencing array elements.


The new element value to be stored at the specified position.

SetAt will not cause the array to grow. Use SetAtGrow if you want the array to grow automatically.

You must ensure that your index value represents a valid position in the array. If it is out of bounds, then the Debug version of the library asserts.

See the example for GetAt.

Header: afxtempl.h

© 2015 Microsoft