2017-02-02 66 views
1

我想建立一個解決方案,並得到以下錯誤:類型或命名空間名稱‘命名空間’「無法在全局命名空間中找到(是否缺少程序集引用?)

Severity Code Description Project File Line Suppression State Error CS0400 The type or namespace name 'CMSInstall_Controls_WizardSteps_CollationDialog' could not be found in the global namespace (are you missing an assembly reference?) Fortius.CMS D:\Kentico10Migration\GithubMegha\Fortius.CMS\CMS\CMSInstall\install.aspx.designer.cs 390 Active

Designer file is not recognising

"CMSInstall_Controls_WizardSteps_CollationDialog"

/// /// ucCollationDialog control. /// /// /// Auto-generated field. /// To modify move field declaration from designer file to code-behind file. /// protected global::CMSInstall_Controls_WizardSteps_CollationDialog ucCollationDialog;

但另一個解決方案文件具有相同的install.aspx install.aspx.cs install.aspx.desginer.cs文件,但在構建它時沒有錯誤。

+0

該項目是否有相同的參考文件.... – Reniuz

+0

可能有一個nuget包,你已經安裝到一個項目,但沒有到另一個。 – NineBerry

+1

可能重複的[獲取「類型或名稱空間名稱找不到」,但一切似乎沒問題嗎?](http://stackoverflow.com/questions/3304741/getting-type-or-namespace-name-could-not-be -found,但是,一切-似乎-OK) –

回答

0

我解決了該問題:

問題是其在設計文件中提供的類是存在於被排除在解決方案中的文件。我已經包含所有文件,錯誤消失了!

Yipieee !!

相關問題