| 发表于:2007-06-25 11:12:553楼 得分:0 |
public string getstr(string str) // 中文转换 { string temp = null; try { string temp_p = str; // 获取得到的值 byte[] temp_t = temp_p.getbytes( "iso8859-1 "); // 进行转换 temp = new string(temp_t); // 重新生成一个新的字符串 }catch(exception e1) { e1.printstacktrace(); } return temp; // 返回这个新值 } | | |
|