【发布时间】:2014-02-12 10:37:29
【问题描述】:
由于 MahApps.Metro,我很难使用 SmartAssembly 6(评估/试用)将我在 C# WPF 项目中的所有依赖项捆绑到单个 exe 中。
这个结论是在创建一个只有 MahApps.Metro 的完全空的项目时得出的,但仍然无法捆绑它。
它抛出一个带有内部异常System.IO.FileNotFoundException: Could not load file or assembly 'System.Windows.Interactivity, Version=4.5.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35' or one of its dependencies. The system cannot find the file specified.的异常
我花了一天半的时间试图解决这个问题,谷歌搜索错误,尝试我能找到的每一个建议,并在 MahApps.Metro 官方聊天 (https://gitter.im/MahApps/MahApps.Metro) 中发帖。我尝试了各种变体,其中我删除了 System.Windows.Interactivity dll、添加了它、将它移动到另一个路径等。
使用来自 NuGet 的最新 MahApps.Metro 包和 .NET 4.5。当我从 Visual Studio 2012 运行程序或从 Debug/Release 运行应用程序时,该程序可以工作。
以前有人遇到过这个问题吗?你是怎么解决的?问题是捆绑应用程序(SmartAssembly 6)还是 MahApps.Metro?您知道或认为是否有任何其他捆绑程序可以与 MahApps.Metro 一起使用?
【问题讨论】:
标签: c# wpf mahapps.metro smartassembly