已知Unicode编码如\u7528 如何在C#下转换为字符

来源:百度知道 编辑:UC知道 时间:2024/05/22 06:51:35
应该是中文就是中文字符 中英日混合串也应能显示为相应的语言
非常感谢 我忘了补充 我是在一个windows Application下 是不能找到System.Web.HttpUility的

C#?如下:UrlEncode,
Response.Redirect("2.aspx?username="+System.Web.HttpUtility.UrlEncode(str1)+"&email=" +HttpUtility.UrlEncode(str2));
跟:UrlDecode
Response.Write("欢迎你:"+HttpUtility.UrlDecode(Request.QueryString["username"].ToString)+ HttpUtility.UrlDecode(Request.QueryString["email"].ToString()));
至于具体的用法,你查下msdn。。。