Mono Class Library: System.String Overview | Members

System.String Constructor

Constructs and initializes a new instance of string using an array of Unicode characters, the index within array at which to start copying characters, and the number of characters to be copied. [Edit]

public String (char[] value, int startIndex, int length)

Parameters

value
An array of Unicode characters. [Edit]
startIndex
A int containing the index within the array referenced by value from which to start copying. [Edit]
length
A int containing the number of characters to copy from the value array. If length is zero, string.Empty is created. [Edit]

Exceptions

TypeReason
ArgumentNullExceptionvalue is a null reference. [Edit]
ArgumentOutOfRangeException

startIndex or length is less than zero.

-or-

The sum of startIndex and length is greater than the number of elements in value .

[Edit]

Remarks

This constructor copies the sequence Unicode characters found at value between indexes startIndex and startIndex + length - 1. [Edit]

Requirements

Namespace: System
Assembly: mscorlib (in mscorlib.dll)
Assembly Versions: 1.0.5000.0, 2.0.0.0