简体   繁体   English

Visual Studio 2012不会生成exe

[英]Visual Studio 2012 does not generate exe

I've a C++ project in Visual Studio 2012 Express, and I started having problems lately. 我在Visual Studio 2012 Express中有一个C ++项目,最近我开始遇到问题。 When I compile the project it works, nothing wrong, however when I try to execute it the .exe disappears. 当我编译项目时,它没有问题,但是,当我尝试执行该项目时,.exe消失了。 I mean, I compile the project, the project generates the exe file with no problems, but if I try to execute it from Visual Studio or directly from the output directory, Windows say to me: 我的意思是,我编译该项目,该项目会毫无问题地生成exe文件,但是如果我尝试从Visual Studio或直接从输出目录执行该文件,Windows会对我说:

Cannot start the program 'C:\Users\Adrian\Dropbox\MyApp\Debug\MyApp.exe'.
The system can not find the file specified

If I create another project, Hello World for example, there is no problem and the exe generates and executes good. 如果创建另一个项目(例如Hello World),则不会出现问题,并且exe会生成并执行良好。 So I guess the problem is specific to my project. 所以我想问题是我的项目特有的。 I tried disabling Avast (because maybe he delete the file) and the problem persists. 我尝试禁用Avast(因为可能是他删除了文件),问题仍然存在。 Also I create another project, including the files and... the problem is still here... I check the project options, specifically general and debug options and I see nothing wrong. 此外,我还创建了另一个项目,包括文件和...问题仍然存在...我检查了项目选项,特别是常规选项和调试选项,但我没有发现任何错误。 So does anyone have an idea what may be wrong? 那么,有谁知道可能出什么问题?

The output directory is $(SolutionDir)$(Configuration)\\ and I'm compiling in Debug mode. 输出目录是$(SolutionDir)$(Configuration)\\并且我正在调试模式下进行编译。

The windows error message is misleading. Windows错误消息具有误导性。 It should state that, loading a library (dll) failed. 它应该指出,加载库(dll)失败。 You might run the program with a process monitor (see: http://technet.microsoft.com/en-us/sysinternals/bb896645.aspx ) 您可以使用进程监视器来运行程序(请参阅: http : //technet.microsoft.com/zh-cn/sysinternals/bb896645.aspx

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM