What am I doing wrong? I have a simple console app in VS08. When I hit Publish, it creates a setup.exe in the target folder. When you run setup.exe, it goes through the motions of installing, but it also runs the app, which is undesirable to say the least. Is there a setting I'm missing or something?
我究竟做错了什么?我在VS08中有一个简单的控制台应用程序。当我点击Publish时,它会在目标文件夹中创建一个setup.exe。当你运行setup.exe时,它会经历安装的动作,但它也运行应用程序,至少可以说这是不可取的。有没有我缺少的设置或什么?
2 个解决方案
#1
You're creating a ClickOnce installer. You don't need that. Just choose "Project" and then "Build ____" from the menu. That will create a *.exe file in your project folder under /bin/Debug/
or /bin/Release/
. If there are no dependencies outside of the .Net framework (like extra assemblies (dlls) or an app.config file), and the framework is already installed on the machines that will use the app, then you can just distribute the exe file by itself.
您正在创建ClickOnce安装程序。你不需要那个。只需选择“项目”,然后从菜单中选择“构建____”即可。这将在/ bin / Debug /或/ bin / Release /下的项目文件夹中创建一个* .exe文件。如果.Net框架之外没有依赖项(如额外程序集(dll)或app.config文件),并且框架已经安装在将使用该应用程序的计算机上,那么您只需通过以下方式分发exe文件:本身。
#2
Is this a ClickOnce setup? Maybe you want to create a separate project of type "Setup and Deployment" to create an MSI installer instead which does not start your application?
这是ClickOnce设置吗?也许你想创建一个“安装和部署”类型的单独项目来创建一个MSI安装程序而不启动你的应用程序?
From your question it is actually not clear what you are trying to do. Do you wnat to install the application on a target system or do you simply want to copy it to some folder and then execute it?
从您的问题来看,实际上并不清楚您要做什么。您是否想在目标系统上安装应用程序,或者您只是想将其复制到某个文件夹然后执行它?
#1
You're creating a ClickOnce installer. You don't need that. Just choose "Project" and then "Build ____" from the menu. That will create a *.exe file in your project folder under /bin/Debug/
or /bin/Release/
. If there are no dependencies outside of the .Net framework (like extra assemblies (dlls) or an app.config file), and the framework is already installed on the machines that will use the app, then you can just distribute the exe file by itself.
您正在创建ClickOnce安装程序。你不需要那个。只需选择“项目”,然后从菜单中选择“构建____”即可。这将在/ bin / Debug /或/ bin / Release /下的项目文件夹中创建一个* .exe文件。如果.Net框架之外没有依赖项(如额外程序集(dll)或app.config文件),并且框架已经安装在将使用该应用程序的计算机上,那么您只需通过以下方式分发exe文件:本身。
#2
Is this a ClickOnce setup? Maybe you want to create a separate project of type "Setup and Deployment" to create an MSI installer instead which does not start your application?
这是ClickOnce设置吗?也许你想创建一个“安装和部署”类型的单独项目来创建一个MSI安装程序而不启动你的应用程序?
From your question it is actually not clear what you are trying to do. Do you wnat to install the application on a target system or do you simply want to copy it to some folder and then execute it?
从您的问题来看,实际上并不清楚您要做什么。您是否想在目标系统上安装应用程序,或者您只是想将其复制到某个文件夹然后执行它?