0
在此先感谢您提供任何和所有帮助。如果字段值为空,则SSRS函数返回#Error
我的代码是:
Public Function StripHTML(value As String) As String
Return System.Text.RegularExpressions.Regex.Replace(value, "<(.|\n)*?>", "")
End Function
然后我调用函数从一个文本框。这非常有效,除非数据集中有空值。我试图补偿空值,但是RDLC文件生成一条错误消息,说明它无法显示子报表。
Public Function StripHTML(value As String) As String
if isnothing(value) then return value
else
Return System.Text.RegularExpressions.Regex.Replace(value, "<(.|\n)*?>", "")
end if
End Function
我也想告诉它,如果null
返回" "
。
我没有运气...
任何想法?并再次感谢。
非常感谢!我很感激。 – user299411 2010-03-25 11:45:20
不客气。 – SoftwareGeek 2010-03-25 22:28:59