如何在 Visual Studio 2008 中创建单个可执行文件?

发布于 2024-08-18 21:25:02 字数 207 浏览 2 评论 0原文

我在 Visual Studio 2008、.NET 3.5 中创建了一个 Windows 窗体应用程序。 现在我想完成我的项目,即创建一个 .exe 文件,我可以将其提供给某人,他将能够在他的计算机上运行它。

在我的项目文件中,我找到了 bin/Debug 目录,其中有一个 .exe 文件。 我可以按原样使用该文件吗?或者我错过了一些重要的最终确定过程?

谢谢 !

I've created a Windows Forms Application in Visual Studio 2008, .NET 3.5.
Now I want to finalize my project, i.e. to create a single .exe file which I can give to someone and he will be able to run it on his computer.

In my project files I found bin/Debug directory where I see a .exe file.
Can I just use this file as is, or I am missing some important finalizing procedure ?

Thanks !

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(4

淑女气质 2024-08-25 21:25:02

只要 EXE 没有依赖项,您就可以直接使用它。如果其中有任何 dll 文件,则需要包含它们(或使用 ILMerge命令行实用程序将它们组合起来)。但是,您可以忽略任何生成的 pdb 或 xml 文件。

附带说明一下,如果您计划部署项目,则应该在发布版本中进行编译(输出将位于 bin/Release 中)

You can just take the EXE as long as it has no dependencies. If there are any dll files in there, you need to include them (or use the ILMerge command line utility to combine them). You can, however, ignore any generated pdb or xml files.

As a side note, you should be compiling in release if you plan on deploying your project (the output will be in bin/Release)

初熏 2024-08-25 21:25:02

你的问题不清楚。如果您的解决方案输出只是一个 exe 文件,那么是的,您可以在 bin\debug 中放弃该 exe 文件。

但您必须分发用于发布目的的 bin\Release\ exe,而不是 bin\debug\ exe。

You are not clear in you question. If your solutions output is just a single exe file, then Yes, you can give away the exe file in bin\debug.

But instead of bin\debug\ exe you must distribute the bin\Release\ exe which is meant for release purpose.

韵柒 2024-08-25 21:25:02

为了使 ILMerge 更容易,请使用 codeplex 中的 GUI 工具,网址为 http://ilmergegui.codeplex.com/

如果这是一个商业应用程序,则多个商业混淆器允许创建单个 exe。

To make the ILMerge easier, use the GUI tool from codeplex at http://ilmergegui.codeplex.com/

If this is a commercial application, several commercial obfuscators allow creating a single exe.

心凉 2024-08-25 21:25:02

在 SetiSeeker 响应中,链接 http://ilmergegui.codeplex.com/ 无法访问

In SetiSeeker response the link http://ilmergegui.codeplex.com/ is not reachable

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文