Friday 3 March 2017

c# decode special characters

public string DecodeSpecial(string strVtext)
{
if (!string.IsNullOrEmpty(strVtext))
{
//strVtext=strVtext.Replace("&", "&amp;").Replace("/&", "&quot;").Replace("/'", "&apos;").Replace("<", "&lt;").Replace(">", "&gt;");
//strVtext= new System.Xml.Linq.XText(strVtext).ToString();
//strVtext=System.Web.HttpUtility.HtmlEncode(strVtext);
}
return strVtext;
}