Gets or sets the maximum number of characters that can be contained in the memory allocated by the current instance.
Assembly: mscorlib (in mscorlib.dll)
The value specified for a set operation is less than the current length of this instance.
The value specified for a set operation is greater than the maximum capacity.
does not affect the string value of the current instance. can be decreased as long as it is not less than Length.
The StringBuilder dynamically allocates more space when required and increases accordingly. For performance reasons, a StringBuilder might allocate more memory than needed. The amount of memory allocated is implementation-specific.
.NET FrameworkSupported in: 4.6, 4.5, 4, 3.5, 3.0, 2.0, 1.1
.NET Framework Client ProfileSupported in: 4, 3.5 SP1
XNA FrameworkSupported in: 3.0, 2.0, 1.0
Portable Class LibrarySupported in: Portable Class Library
Supported in: Windows Phone 8.1
Supported in: Windows Phone Silverlight 8.1
Supported in: Windows Phone Silverlight 8