不同版本的C ++库
在vista上使用Visual Studio 2008编译一个简单的C ++项目后,一切在原始vista机器和其他vista计算机上运行良好。但是,将其移动到XP框会导致错误消息:由于应用程序配置不正确,应用程序无法启动。
After compiling a simple C++ project using Visual Studio 2008 on vista, everything runs fine on the original vista machine and other vista computers. However, moving it over to an XP box results in an error message: "The application failed to start because the application configuration is incorrect".
我需要做什么所以我编译的EXE工程在XP和Vista?我在几个月前遇到了同样的问题,只是修改了一些项目的设置修复了它,但我不记得我改变了哪些。
What do I have to do so my compiled EXE works on XP and Vista? I had this same problem a few months ago, and just fiddling with some settings on the project fixed it, but I don't remember which ones I changed.
您需要在目标计算机上安装Visual Studio 2008运行时:
You need to install the Visual Studios 2008 runtime on the target computer:
或者,您也可以链接运行时静态,在项目属性窗口中转到:
Alternatively, you could also link the run time statically, in the project properties window go to:
c ++ - >代码生成 - >运行
库和选择多线程
/ MT
c++ -> Code Generation -> Runtime Library and select "multi-threaded /MT"