Bridge

String..::..Substring Method (Int32, Int32)

Retrieves a substring from this instance. The substring starts at a specified character position and has a specified length.

Namespace:  System
Assembly:  Bridge (in Bridge.dll)

Syntax


[NameAttribute]
public string Substring(
	int start,
	int length
)
<NameAttribute> _
Public Function Substring ( _
	start As Integer, _
	length As Integer _
) As String
[NameAttribute]
public:
String^ Substring(
	int^ start, 
	int^ length
)

Parameters

start
Type: System..::..Int32
length
Type: System..::..Int32
The number of characters in the substring.

Return Value

A string that is equivalent to the substring of length length that begins at startIndex in this instance, or Empty if startIndex is equal to the length of this instance and length is zero.

Exceptions


ExceptionCondition
System..::..ArgumentOutOfRangeExceptionstartIndex plus length indicates a position not within this instance.-or- startIndex or length is less than zero.