2015-11-04 34 views
0

我得到以下編譯錯誤集中定義:類型「爲Expando」在未被引用

The type 'Expando' is defined in an assembly that is not referenced. 
You must add a reference to assembly 'Westwind.Utilities, Version=2.64.0.0, 
Culture=neutral, PublicKeyToken=6f7d66a3bb7de652'. 

的事情是,我要那個版本的組件的參考...我認爲這個問題是由於一個類庫。

我ClassLibrary有以下類:

public class Generic_AnswerFile : Expando { ... } 

和我的測試控制檯具有以下類:

public class Specific_AnswerFile : Generic_AnswerFile { ... } 

的Specific_AnswerFile將無法編譯。任何想法爲什麼?這兩個項目是.NET 4.0,並有正確的.NET 4.0版本Expando的是他的裝配

,這意味着只有在GAC定義的Westwind.Utilities 2.64

+0

,檢查的csproj文件,檢查是否有如何指定引用任何可能相關的差異。 – hvd

回答

0

類型的引用。雖然你有參考它,但它會加載失敗。加載它正確,你需要在你的配置文件,如果你說的這兩個項目具有參考定義它在裝配標記

<add assembly="Expando, Version=1.0.0.0, Culture=neutral, PublicKeyToken=[MyPublicKeyToken]"/> 
相關問題