1

我在 Visual Studio 2008 中使用 c# 桌面基础应用程序,它是 zip 制造商,所以我想让 .exe 文件必须在不安装的情况下运行。那么任何人都可以帮我做到这一点吗?

我想在该 exe 中包含所有 .dll 文件,并希望在不安装它的情况下运行它。

4

4 回答 4

2

ILMerge allows you to package your dependent DLLs into your .exe file.

http://research.microsoft.com/en-us/people/mbarnett/ilmerge.aspx

于 2012-05-14T08:11:52.420 回答
0

By default VS makes .exe file goto your project debug folder and use it.

于 2012-05-14T08:08:57.210 回答
0

Click on Build!

The Exe is created in the "\bin\Debug" Folder.

Copy the Exe From the "\bin\Debug" Folder.

If more Dll's are present use IlMerge to pack all the dll and exe to one file.

An alternative to IlMerge is .NETZ

Use the new exe without installation!

于 2012-05-14T08:10:35.867 回答
0

作为 ILMerge 的替代方案,您可以将 DLL 打包为嵌入式资源并按需加载它们。

请参阅http://blogs.msdn.com/b/microsoft_press/archive/2010/02/03/jeffrey-richter-excerpt-2-from-clr-via-c-third-edition.aspx

于 2012-05-14T08:21:22.617 回答