visual-studio-2010 - 在 Windows 7 中构建的 VC++ 程序不能在 Windows Xp 上运行

标签 visual-studio-2010 visual-c++ windows-7 windows-xp

我创建了一个小WIN32 Console Application在 Windows 7 中的 Visual C++ 中。

当我尝试在 Windows Xp 上运行这个应用程序时,它给了我一个错误提示

This application has failed to start because MSVCR100D.dll was not found. Re-installing the application may fix this problem.



那么我如何静态构建这个应用程序,以便它包含 MSVCR100D.dll ?或者

我必须复制MSVCR100D.dll形成 Windows 7 并将其粘贴到 Windows Xp 中的某个位置?

谢谢。

最佳答案

MSVCR100D.dll 不是 Win7 DLL,而是 MSVC2010 DLL。您可以通过在项目属性(在 C/C++ -> 代码生成下)将 RuntimeLibrary 从 MD(d) 更改为 MT(d) 来使用静态链接。

关于visual-studio-2010 - 在 Windows 7 中构建的 VC++ 程序不能在 Windows Xp 上运行,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/5244432/

相关文章:

powershell - 从文本文件的文件名列表中将文件从一个文件夹移动到另一个文件夹

jquery - 包含 bool 值的 html5 数据属性

c# - 是否可以从 vb.net dll 中的 dll 导入 c# 类?

C++ 新手 : destructor

c++ - 如何修复 "faulting module msvcr100.dll"

c# - 如何为 WPF 4 使用 WinRT 转换

windows - 尽管 Web 浏览器在同一台计算机上运行,​​但 Ping 请求超时

c++ - 通过 Visual Studio 运行 GCC

visual-studio-2010 - 如何在 Visual Studio 中创建一个不打算编译的项目?

c++ - 在 Visual Studio 中编写独立程序的最佳方法是什么?