我如何将Visual Studio中的应用程序导出为可执行文件 [英] How I can export an application in visual studio as an executable

查看:956
本文介绍了我如何将Visual Studio中的应用程序导出为可执行文件的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

如何在visual studio中导出应用程序(windows窗体)作为可执行文件,在未安装visual studio的电脑上运行



对不起我的意思导出是在未安装框架的情况下在PC上运行还是将其导出为二进制或机器语言

How I can export an application (windows form) in visual studio as an executable to run on a pc where visual studio is not installed

sorry what I meant was that export to run on the pc without the framework installed or export it to binary or machine language

推荐答案

运行应用程序不需要Visual Studio。我可以告诉你更多:甚至不需要建立一个项目或解决方案(惊喜?)。 MS只使用MSBuild.EXE,它与(免费分发的).NET Framework捆绑在一起,以及C#和VB.NET编译器。



并且没有任何内容出口。事实上,如果不将.NET应用程序构建为可执行文件,则无法运行.NET应用程序。只需在项目中找到它。它位于输出目录中。要找出输出目录的位置,请查看项目选项。



-SA
Visual Studio is not needed to run the application. I can tell you more: it is not even needed to build a project or a solution (surprise?). MS simply uses MSBuild.EXE, which is bundled with (freely distributed) .NET Framework, as well as C# and VB.NET compilers.

And there is nothing to export. If fact, it is not possible to run a .NET application without building it into executable file(s). Just find it inside your project. It is in the output directory. To find out where is the output directory, look at the project options.

—SA


如果它是一个简单的程序,你需要做的就是进入bin文件夹,并获取exe文件。假设您已安装框架,即使没有安装,也可以正常运行。如果您只是在编译时创建调试版本,则可执行文件位于/ bin / Debug中。对于一个简单的应用程序,将有一个pdb,一个exe.config和一个exe文件。 pdb文件包含调试符号。只是尝试执行exe。它会工作。
If it is a simple program, all you need to do is go into the bin folder, and get the exe file. That will run just fine without even installing assuming you have the framework installed. If you are just creating a debug version when compiling, then the executable is in /bin/Debug. for a simple application, there will be a pdb, an exe.config, and an exe file. The pdb file contains the debug symbols. Just try executing the exe. it will work.


您不导出应用程序。首先创建一个Windows窗体应用程序,该应用程序被编译为可执行文件。
You don't export an application. You begin by creating a Windows Form application, which is compiled into an executable.


这篇关于我如何将Visual Studio中的应用程序导出为可执行文件的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆