Earlier I have write blog post on how to format code and convert it into Html
This post will explain you How to remove HTML from String.
To Remove HTML from String you can make use of following function.
public string RemoveHTML(string strSource)
{
//Here strSource is string containing HTML Code
return Server.HtmlDecode(Regex.Replace(strSource, "<(.|\n)*?>", ""));
}
No comments:
Post a Comment