【发布时间】:2015-05-08 12:10:56
【问题描述】:
另一个“*.exe 不是有效的 win32 应用程序”问题。我有 Visual Studio 2013。我的 C++ 项目在 Windows Server 2008、Windows 8、Windows 7 上运行良好。但在 Windows Server 2003 上却不行。
我在 Stackoverflow 上查看了所有其他类似的问题,但找不到合适的解决方案。我查看了this page 并通过更改Configuration Properties > General page, change Platform Toolset to "(v120_xp)". 应用了修复程序
我仍然有这个问题。文件大小看起来也很正常。我用多线程(/MT)和Win32解决方案平台编译它。
我的包含文件是:
#include "LoadController.h"
#include <iostream>
#include <chrono>
#include <thread>
#include <random>
#include <ctime>
#include <string>
#include <stdio.h>
我通过创建平面“新项目”来创建项目(我不知道这是否重要)。我不使用它调用任何其他应用程序。该项目仅包含一个类。
提前谢谢你。
【问题讨论】:
-
为什么stackoverflow.com/questions/11305633/… 不是您问题的有效答案?
-
使用
dumpbin检查 exe 标头中的操作系统和子系统值。