Note
Access to this page requires authorization. You can try signing in or changing directories.
Access to this page requires authorization. You can try changing directories.
[This documentation is for preview only, and is subject to change in later releases. Blank topics are included as placeholders.]
Removes the specified range of characters from this instance.
Namespace: System.Text
Assembly: mscorlib (in mscorlib.dll)
Syntax
'Declaration
Public Function Remove ( _
startIndex As Integer, _
length As Integer _
) As StringBuilder
public StringBuilder Remove(
int startIndex,
int length
)
public:
StringBuilder^ Remove(
int startIndex,
int length
)
member Remove :
startIndex:int *
length:int -> StringBuilder
public function Remove(
startIndex : int,
length : int
) : StringBuilder
Parameters
- startIndex
Type: System. . :: . .Int32
The zero-based position in this instance where removal begins.
- length
Type: System. . :: . .Int32
The number of characters to remove.
Return Value
Type: System.Text. . :: . .StringBuilder
A reference to this instance after the excise operation has completed.
Remarks
The current method removes the specified range of characters from the current instance. The characters at (startIndex + length) are moved to startIndex, and the string value of the current instance is shortened by length. The capacity of the current instance is unaffected.
Note
The Remove method modifies the value of the current StringBuilder instance and returns that instance. It does not create and return a new StringBuilder object.
.NET Framework Security
- Full trust for the immediate caller. This member cannot be used by partially trusted code. For more information, see dd66cd4c-b087-415f-9c3e-94e3a1835f74.