c# - 我如何在 dot net Core 中排列应用程序 dll 文件

标签 c# winforms .net-core

我在 dotnet core 3.1 中构建了一个应用程序
构建后我在 bin 文件夹中看到很多 dll 和 xml
这里屏幕截图
dll hell
我希望它看起来像这样
enter image description here
有人可以帮我:-(((((

最佳答案

在 .net 框架中,您可以使用 AssemblyBinding probing在 app.exe.config 中并使用 Post Build Events Command Line在 Visual Studio 中移动自定义文件夹中的 dll 和 xml。
在 .net 核心 3.1 additionalProbingPaths似乎不能正常工作,但您仍然可以使用 Post Build Events Command Line将您的 xml 移动到自定义文件夹中。
注:1。 AssemblyBinding probingadditionalProbingPaths会影响你的程序集加载dll location.2。如果您不知道 Post Build Events Command Linethe guide line .
请参阅以下有关探测路径的问题。
Additional probing paths for .NET Core 3 migration
donet/sdk issue .
终于找到nulastudio.NetCoreBeauty库,这似乎是您想要的功能。

关于c# - 我如何在 dot net Core 中排列应用程序 dll 文件,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/63063996/

相关文章:

c# - 如何以编程方式滚动 TreeView?

winforms - 在 Winform 中将 UserControl 从工作线程添加到主 UI 线程时发生跨线程冲突

c# - 在 ASP.NET Core 2 中排除文件夹

c# - Entity Framework Core 1.1.2 迁移异常

c# - .NET对象事件和处置/GC

c# - 如何为身份添加缺少的迁移? (无效的对象名称 'dbo.AspNetRoles' )

c# - 当应用程序以 xsession 启动时如何全屏显示 GTK# 窗口?

c# - Winform 设计器应用程序

c# - 自定义验证属性的依赖注入(inject)

c# - Web 服务调用中的 "Impersonating" session