C# StringBuilder Append(SByte)

Description

StringBuilder Append(SByte) Appends the string representation of a specified 8-bit signed integer to this instance.

Syntax

StringBuilder.Append(SByte) has the following syntax.


[CLSCompliantAttribute(false)]
public StringBuilder Append(
  sbyte value
)

Parameters

StringBuilder.Append(SByte) has the following parameters.

  • value - The value to append.

Returns

StringBuilder.Append(SByte) method returns A reference to this instance after the append operation has completed.

Example

Appends the string representation of a specified 8-bit signed integer to this instance.


// www.java 2 s.  c om
using System;
using System.Text;

class Sample 
{
    public static void Main() 
    {
        System.Text.StringBuilder sb = new 
                    System.Text.StringBuilder("The range of an 8-bit signed integer: ");
        sb.Append(SByte.MinValue).Append(" to ").Append(SByte.MaxValue);
        Console.WriteLine(sb);
    }
}

The code above generates the following result.





















Home »
  C# Tutorial »
    System.Text »




ASCIIEncoding
Encoding
EncodingInfo
StringBuilder
UnicodeEncoding
UTF8Encoding