Remove HTML tags from string. Somewhere we need to parse some string which is received by some responses like Httpresponse from the server.
So we need to parse it.
Here I will show how to remove html tags from string.
// sample
text with tags
string
str = "<html><head>sdfkashf
sdf</head><body>sdfasdf</body></html>";
// regex
which match tags
System.Text.RegularExpressions.Regex rx = new
System.Text.RegularExpressions.Regex("<[^>]*>");
// replace
all matches with empty strin
str = rx.Replace(str, "");
//now str
contains string without html tags

aishwar nigamPosted Oct 15, 2018, 1:10 PM
Not working
Sweta JaiswalPosted Jan 30, 2018, 11:20 AM
Is this going to remove just the HTML tags or any value in the tag format (e.g. <?160>)