IntelliSense:cannot open source file

http://stackoverflow.com/questions/7623980/intellisense-cannot-open-source-file-curl-h-in-c

Under Visual Studio 2010 & 2012

  • Right click on your project
  • select Properties
  • Expand Configuration Properties
  • Click on the VC++ Directories
  • Add the path to your file into the "Reference Directories" item

刚下了一个VS2010试用,建了一个MFC应用程序,然后编译运行,一切正常,但是在错误列表里有一个这样的错误
IntelliSense: #error directive: Please use the /MD switch for _AFXDLL builds c:\program files (x86)\microsoft visual studio 10.0\vc\atlmfc\include\afxver_.h

Go to Config Properties->C/C++-> Code Generation ->. Double-click "Runtime Library" and set to "Multi-threaded Debug DLL (/MDd)" . If this value already appears to be set, make sure it is by selecting it again

VS2005、VS2010等VS系列IDE在MFC开发过程中,Resource View标签打不开,问题为“opened in other editor”

问题描述:VS2005、VS2010等VS系列IDE在MFC开发过程中,Resource View标签打不开,问题为“opened in other editor”

可能原因:

(1)resource.h文件被打开了,可能你打开的文件比较多,该文件就会被隐藏到后面的箭头中了,

(2)在为新对话框添加类的时候,VS崩溃,再次打开就出现了这个问题,

解决方法,分别对应:

(1)打开关闭的resource.h文件,可以再打开文件的标签栏中右键关闭所有打开标签,或者通过箭头找到该文件,然后关闭掉它。

(2)打开“.rc”文件,删除所有关于刚才新添加对话框的内容,同时删除新添加的类(如果有,则删除)文件,即可恢复到添加对话框之前的状态

原文地址:https://www.cnblogs.com/Null2051/p/3009388.html