System.Text.StringBuilder.Append Method

Appends a copy of the specified string to this instance.

Syntax

public StringBuilder Append (string value)

Parameters

value
The string to append.

Returns

A reference to this instance after the append operation has completed.

Remarks

The StringBuilder.Append(string) method modifies the existing instance of this class; it does not return a new class instance. Because of this, you can call a method or property on the existing reference and you do not have to assign the return value to a System.Text.StringBuilder object, as the following example illustrates.

code reference: System.Text.StringBuilder.Append#2

If value is null, no changes are made.

The capacity of this instance is adjusted as needed.

Requirements

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