我想序列化的數據結構,並通過參數把它傳遞給另一份報告,這行代碼:爲什麼System.Xml.Serialization.XmlSerializer在SSRS 2005報告中未定義?
Dim s As New System.Xml.Serialization.XmlSerializer(GetType(System.Collections.HashTable))
產生以下錯誤:
An error occurred during local report processing.
The definition of the report '/myReport' is invalid.
There is an error on line 22 of custom code: [BC30002] Type 'System.Xml.Serialization.XmlSerializer' is not defined.
我怎樣才能解決這個得到?我已經能夠在其他代碼行,包括使用完全定義的.NET類如下:
Dim outStream As New System.IO.StringWriter()
和
Private colorMapping As New System.Collections.Hashtable()
任何想法,爲什麼會失敗?這是SQL Server報告服務2005
我對報告服務並不熟悉,但我猜你需要在項目中添加對'System.Xml'的引用 – John 2010-01-15 15:17:38
當然!謝謝 - 如果你創建這個答案,我會接受它。 – 2010-01-15 15:40:16