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 all characters from the current StringBuilder instance.
Namespace: System.Text
Assembly: mscorlib (in mscorlib.dll)
Syntax
'Declaration
Public Function Clear As StringBuilder
public StringBuilder Clear()
public:
StringBuilder^ Clear()
member Clear : unit -> StringBuilder
public function Clear() : StringBuilder
Return Value
Type: System.Text. . :: . .StringBuilder
An object whose Length is 0 (zero).
Remarks
Clear is a convenience method that is equivalent to setting the Length property of the current instance to 0 (zero).
Calling the Clear method does not modify the current instance's Capacity or MaxCapacity property.
.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.