Friday, August 16, 2013

IntelliSense: #error directive: Please use the /MD switch for _AFXDLL builds in Visual Studio 2010 MFC project

ERROR:    

error C2001: newline in constant

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    81    3



   
Solution:
There's a bug where the settings of a generated MFC project would show "Multi-threaded Debug DLL (/MDd)"; however, it doesn't pass that argument to the intellisense engine. To workaround this problem, please try the following:

Step 1. Right-click the Project.

Step 2. Go to Config Properties->C/C++-> Code Gen ->. 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 (it should then appear as bold).

Step 3. Click OK.

Done!

No comments:

Post a Comment

How to enable hotspot in TPG iPhone

 By default, the hotspot does not work on the phone. It will ask you to contact the provider. This video will help you bypass the network ...