2011-05-11 57 views
2

繁殖:的DataForm沒有在Silverlight中工作5

  1. 創建一個Silverlight項目
  2. 把它交給版本5
  3. 添加到Silverlight工具包引用(使用的NuGet或直接)
  4. 添加一個DataForm到你的頁面
  5. 這是DataForm構造函數拋出的異常:
    {System.IO.FileNotFoundException: Could not load file or assembly 'System.Windows.Controls.Data.Input, Version=2.0.5.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified. [IO.FileName_Name] Arguments: System.Windows.Controls.Data.Input, Version=2.0.5.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35 Debugging resource strings are unavailable. Often the key and arguments provide sufficient information to diagnose the problem. See http://go.microsoft.com/fwlink/?linkid=106663&Version=5.0.60401.00&File=mscorlib.dll&Key=IO.FileName _Name at System.Windows.Controls.DataForm..ctor()}
  6. 翻回到Silverlight 4的
  7. 現在一切都很酷再次

怪異注:它在VS /相關工作經驗的工作。混合5設計師

任何想法??解決方法???

回答

0

發現一個非常奇怪的解決方法:在我將SL版本返回到4之後,將其重新返回到5,一切正常! (?!?)

無論如何我確定重新編譯SL SL的源代碼,目標是SL5將有所幫助。

+0

問題的性質對我來說是相同的,但是這個解決方案不起作用,但是如果我使用System.Windows.Controls.Data.DataForm.Toolkit.dll爲silverlight 4 dataform工作而構建,但只要將其更改爲System。 silverlight 5的Windows.Controls.Data.DataForm.Toolkit再次構建它停止工作。你有沒有遇到類似的問題? – webKite 2012-03-01 10:15:06

+0

@ webbite很有趣。也許發佈最新版本的工作項目。 – Shimmy 2012-03-01 13:11:59

0

我無法解決此問題,同時還需要SL版本4的項目,然後遷移到SL版本5並嘗試添加DataForm。儘管我引用了2011年12月的Silverlight 5工具包,並且由於SL版本4程序集的存在,我添加了對SL5 DataForm的適當引用,但出現錯誤。

不知道如何根據變通方法中的建議「重新返回」和「返回」,但現在我認爲任何從SL 4遷移到SL5並嘗試添加數據表單的用戶都會遇到此問題。最好從一個全新的SL5項目開始,或者忘記使用遷移到SL5的SL4解決方案使用數據表單?

相關問題