我的SSRS数据集返回一个带有HTML的字段,例如
<b>blah blah </b><i> blah </i>.我如何去除所有的HTML标签? 必须使用内联 VB.NET来完成
更改表格中的数据不是一个选项。
找到解决方案 ... = System.Text.RegularExpressions.Regex.Replace(StringWithHTMLtoStrip,“<[^>] +>”,“”)
my SSRS DataSet returns a field with HTML, e.g.
<b>blah blah </b><i> blah </i>.how do i strip all the HTML tags? has to be done with inline VB.NET
Changing the data in the table is not an option.
Solution found ... = System.Text.RegularExpressions.Regex.Replace(StringWithHTMLtoStrip, "<[^>]+>","")
最满意答案
感谢丹尼尔,但我需要它内联完成...这里的解决方案:
= System.Text.RegularExpressions.Regex.Replace(StringWithHTMLtoStrip, "<[^>]+>","")
这里是链接:
http://weblogs.asp.net/rosherove/archive/2003/05/13/6963.aspx http://msdn.microsoft.com/en-us/library/ms157328.aspx
Thanx to Daniel, but I needed it to be done inline ... here's the solution:
= System.Text.RegularExpressions.Regex.Replace(StringWithHTMLtoStrip, "<[^>]+>","")
Here are the links:
http://weblogs.asp.net/rosherove/archive/2003/05/13/6963.aspx http://msdn.microsoft.com/en-us/library/ms157328.aspx
更多推荐
发布评论