从SSRS 2005中的字符串剥离HTML(VB.NET)(Strip HTML from string in SSRS 2005 (VB.NET))

编程入门 行业动态 更新时间:2024-10-10 21:22:43
从SSRS 2005中的字符串剥离HTML(VB.NET)(Strip HTML from string in SSRS 2005 (VB.NET))

我的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

更多推荐

本文发布于:2023-08-08 00:21:00,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1466679.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:字符串   HTML   SSRS   Strip   string

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!