每當我嘗試添加一個新的功能區到我的Excel 2010插件項目中,我會收到以下警告消息如何解決此錯誤,「基類」Microsoft.Office.Tools.Ribbon.RibbonCollectionBase「不能設計」
The designer could not be shown for this file because none of the classes within it can be designed. The designer inspected the following classes in the file:
Ribbon2 --- The base class 'System.Object' cannot be designed. ThisRibbonCollection --- The base class
'Microsoft.Office.Tools.Ribbon.RibbonCollectionBase' cannot be designed.
此外,如果我們查看Ribbon1.Designer.cs代碼,錯誤指向這一行:
base.Dispose(disposing);
我不知道哪裏出了問題存在。我在這裏是否缺少其他Office程序集?
(在項目中,我得到了Microsoft.Office.Core
,Microsoft.Office.Interop.Excel
,Microsoft.Office.Tools
,Microsoft.Office.Tools.Common
,Microsoft.Office.Tools.Excel
,Microsoft.Office.Tools.Common.v4.0.Utilities
,Microsoft.Office.Tools.v4.0.Framework
)
誰能幫助?謝謝。