PowerTCP Mail for .NET
CopyTo(Array) Method
See Also  Send comments on this topic.
Dart.PowerTCP.Mail Namespace > MailboxCollection Class > CopyTo Method : CopyTo(Array) Method




array
The one-dimensional Array that is the destination of the elements copied from ArrayList. The Array must have zero-based indexing.
Copies the entire collection to a compatible one-dimensional Array.

Syntax

Visual Basic (Declaration) 
Public Overloads Overrides Sub CopyTo( _
   ByVal array As Array _
) 
Visual Basic (Usage)Copy Code
Dim instance As MailboxCollection
Dim array As Array
 
instance.CopyTo(array)
C# 
public override void CopyTo( 
   Array array
)
Managed Extensions for C++ 
public: void CopyTo( 
   Array* array
) override 
C++/CLI 
public:
void CopyTo( 
   Array^ array
) override 

Parameters

array
The one-dimensional Array that is the destination of the elements copied from ArrayList. The Array must have zero-based indexing.

Exceptions

ExceptionDescription
System.ArgumentNullExceptionarray is a null reference (Nothing in Visual Basic).
System.ArgumentExceptionarray is multidimensional.
System.InvalidCastExceptionThe type of the source ArrayList cannot be cast automatically to the type of the destination array.

Remarks

The specified array must be of a compatible type.

This method uses Array.Copy to copy the elements.

Requirements

Target Platforms: Microsoft .NET Framework 2.0

See Also

Documentation Version 3.2
© 2010 Dart Communications. All Rights Reserved.