经过转换得到的字串无法还原
string strText = System.Text.Encoding.ASCII.GetString(System.Text.Encoding.Default.GetBytes("我"));
strText = System.Text.Encoding.Default.GetString(System.Text.Encoding.ASCII.GetBytes(strText));
MessageBox.Show(strText);
得到的并不是"我"
我要怎么样才能得到原来的字符?
string strText = System.Text.Encoding.ASCII.GetString(System.Text.Encoding.Default.GetBytes("我"));
strText = System.Text.Encoding.Default.GetString(System.Text.Encoding.ASCII.GetBytes(strText));
MessageBox.Show(strText);
得到的并不是"我"
我要怎么样才能得到原来的字符?
strText = System.Text.Decoding.Default.GetString(System.Text.Decoding.ASCII.GetBytes(strText));前面编码,下边当然要解码,晕
string strText=System.Text.Decoding.Default.GetString(bydata));梦在流浪 说得正确!