C# Ascii-(byte数组)和字符串互转

    Ascii(Byte数组)转字符串

tString = Encoding.ASCII.GetString(tBytes);

    字符串转Ascii(Byte数组)

tBytes = Encoding.ASCII.GetBytes(tString);

你可能感兴趣的:(C#)