Int32Collection.CopyTo(Int32[], Int32) Method

Definition

Copies all of the Int32 values in a collection to a specified array.

C#
public void CopyTo(int[] array, int index);

Parameters

array
Int32[]

Identifies the array to which content is copied.

index
Int32

Index position in the array to which the contents of the collection are copied.

Implements

Exceptions

index is less than zero.

array is multidimensional.

-or-

The number of items in the source Int32Collection is greater than the available space from index to the end of the destination array.

Applies to

Product Versions
.NET Framework 3.0, 3.5, 4.0, 4.5, 4.5.1, 4.5.2, 4.6, 4.6.1, 4.6.2, 4.7, 4.7.1, 4.7.2, 4.8, 4.8.1
Windows Desktop 3.0, 3.1, 5, 6, 7, 8, 9, 10

See also