Share via


ModelStateDictionary.CopyTo Method

Copies the elements of the model-state dictionary to an array, starting at a specified index.

Namespace:  System.Web.Http.ModelBinding
Assembly:  System.Web.Http (in System.Web.Http.dll)

Syntax

'Declaration
Public Sub CopyTo ( _
    array As KeyValuePair(Of String, ModelState)(), _
    arrayIndex As Integer _
)
'Usage
Dim instance As ModelStateDictionary
Dim array As KeyValuePair(Of String, ModelState)()
Dim arrayIndex As Integer

instance.CopyTo(array, arrayIndex)
public void CopyTo(
    KeyValuePair<string, ModelState>[] array,
    int arrayIndex
)
public:
virtual void CopyTo(
    array<KeyValuePair<String^, ModelState^>>^ array, 
    int arrayIndex
) sealed
abstract CopyTo : 
        array:KeyValuePair<string, ModelState>[] * 
        arrayIndex:int -> unit 
override CopyTo : 
        array:KeyValuePair<string, ModelState>[] * 
        arrayIndex:int -> unit 
public final function CopyTo(
    array : KeyValuePair<String, ModelState>[], 
    arrayIndex : int
)

Parameters

  • arrayIndex
    Type: System.Int32
    The zero-based index in array at which copying starts.

Implements

ICollection<T>.CopyTo(T[], Int32)

See Also

Reference

ModelStateDictionary Class

System.Web.Http.ModelBinding Namespace