是否可以将System.Xml
命名空间导入 SSRS 报告?
有进口
当我在报告代码属性中使用导入语句时,如下所示:
Imports System.Xml
Public Function GetXMLInfo() As String
Dim reader = new XmlReader()
' ....
End Function
我收到以下错误:
The definition of the report '/MyReport' is invalid.
There is an error in line 0 of custom code:
[BC30465] 'Imports' statements must precede any declarations
没有进口
但是,当我在我的代码设置中删除 import 语句时,如下所示:
Public Function GetXMLInfo() As String
Dim reader = new XmlReader()
' ....
End Function
我收到了这个错误:
The definition of the report '/MyReport' is invalid.
There is an error in line 2 of custom code:
[BC30002] Name 'XmlReader' is not defined
问题:如何将XmlReader
类导入到我的 SSRS 代码中?