使用Visual C ++ Express 2010时找不到atlbase.h [英] atlbase.h not found when using Visual C++ Express 2010

查看:588
本文介绍了使用Visual C ++ Express 2010时找不到atlbase.h的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

因此,我尝试将项目从Windows XP的早期版本移至Windows 7的Visual C ++ Express 2010.在找不到atlbase.h的地方,我遇到了各种各样的错误.这不是什么大问题,但我想记录一下我对其他人的解决方案.

So I tried moving my project to Visual C++ Express 2010 on Windows 7 from a previous version on Windows XP. I got all sorts of errors where atlbase.h was not found. This isn't so much a question but I wanted to document what my resolution was for others.

从以前的安装中复制以下PlatformSDK文件,并将它们放在Windows 7计算机上.

Copied the following PlatformSDK files from my previous install and put them on my Windows 7 machine.

PlatformSDK/include/atl

PlatformSDK/include/atl

PlatformSDK/include/mfc

PlatformSDK/include/mfc

PlatformSDK/lib

PlatformSDK/lib

PlatformSDK/src/atl

PlatformSDK/src/atl

然后我在项目属性"中更改VC ++目录以指向那些目录.

I then change the VC++ Directories in the project Properties to point to those directories.

包括目录-

* include/atl

*include/atl

* include/mfc

*include/mfc

图书馆目录-

* lib

源目录-

* src/atl

*src/atl

更改stdafx.h

Make a change to stdafx.h

在此行之后:#include"atlbase.h"

right after this line: #include "atlbase.h"

添加以下行:extern CComModule _Module;

add this line: extern CComModule _Module;

希望您已经准备好出发!可能不是,但也许您过得很好.

Hopefully you're ready to go now! Probably not but perhaps you are well on your way.

推荐答案

ATL和MFC不包括在Visual Studio的免费Express版本中.这是查找包含文件问题背后的主要原因. ATL仍然是WDK的一部分.如果您的ATL与VS的早期版本或WDK分离,则需要分别进行项目设置以更新包含的目录,以便提取ATL * .h文件.有关更多详细信息和讨论,请参见下面的帖子.

ATL and MFC were not included into free Express versions of Visual Studio. This is the primary reason behind the problems locating the include file. ATL still is is part WDK. If you have ATL isntalled with a previous version of VS, or with WDK, you need to go to project setting an update your includ directories respectively, so that ATL *.h files are picked up. See post below for more details and discussion.

  • How to add WTL and ATL to visual studio c++ express 2008
  • Why were MFC, ATL and masm not included in VC++ Express?
  • Please include ATL to VC++2010 Express or Windows SDK

这篇关于使用Visual C ++ Express 2010时找不到atlbase.h的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆