public static string GetGBKPhoneticism(string character)
{
byte[] array = new byte[2];
char[] nowchar = character.ToCharArray();
int first = 0;
int second = 0;
int chrasc = 0;
string sRet = "";
for (int i = 0; i < nowchar.Length; i++)
{
array = System.Text.Encoding.Default.GetBytes(nowchar[i].ToString());
first = (short)(array[0]);
if (array.Length == 1)
{
sRet += nowchar[i];
continue;
}
else
{
second = (short)(array[1]);
}
chrasc = first * 256 + second;
if ((chrasc >= 45217) && (chrasc <= 45252))
{
sRet += "A";
}
else if ((chrasc >= 45253) && (chrasc <= 45760))
{
sRet += "B";
}
else if ((chrasc >= 45761) && (chrasc <= 46317))
{
sRet += "C";
}
else if ((chrasc >= 46318) && (chrasc <= 46825))
{
sRet += "D";
}
else if ((chrasc >= 46826) && (chrasc <= 47009))
{
sRet += "E";
}
else if ((chrasc >= 47010) && (chrasc <= 47296))
{
sRet += "F";
}
else if ((chrasc >= 47297) && (chrasc <= 47613))
{
sRet += "G";
}
else if ((chrasc >= 47614) && (chrasc <= 48118))
{
sRet += "H";
}
else if ((chrasc >= 48119) && (chrasc <= 49061))
{
sRet += "J";
}
else if ((chrasc >= 49062) && (chrasc <= 49323))
{
sRet += "K";
}
else if ((chrasc >= 49324) && (chrasc <= 49895))
{
sRet += "L";
}
else if ((chrasc >= 49896) && (chrasc <= 50370))
{
sRet += "M";
}
else if ((chrasc >= 50371) && (chrasc <= 50613))
{
sRet += "N";
}
else if ((chrasc >= 50614) && (chrasc <= 50621))
{
sRet += "O";
}
else if ((chrasc >= 50622) && (chrasc <= 50905))
{
sRet += "P";
}
else if ((chrasc >= 50906) && (chrasc <= .51386))
{
sRet += "Q";
}
else if ((chrasc >= 51387) && (chrasc <= 51445))
{
sRet += "R";
}
else if ((chrasc >= 51446) && (chrasc <= 52217))
{
sRet += "S";
}
else if ((chrasc >= 52218) && (chrasc <= 52697))
{
sRet += "T";
}
else if ((chrasc >= 52698) && (chrasc <= 52979))
{
sRet += "W";
}
else if ((chrasc >= 52980) && (chrasc <= 53640))
{
sRet += "X";
}
else if ((chrasc >= 53689) && (chrasc <= 54480))
{
sRet += "Y";
}
else if ((chrasc >= 54481) && (chrasc <= 55289))
{
sRet += "Z";
}
else sRet += nowchar[i];
}
return sRet.ToUpper();
}