Home Dashboard Directory Help
Search

Compiler error when using v110_xp platform toolset, Visual Studio 2012 by AC374


Status: 

Closed
 as By Design Help for as By Design


6
0
Sign in
to vote
Type: Bug
ID: 773422
Opened: 12/4/2012 6:50:40 AM
Access Restriction: Public
2
Workaround(s)
view
5
User(s) can reproduce this bug

Description

I am using Visual Studio 2012 with Update 1 on Windows 7 x64. I also have Visual Studio 2010 installed on the same machine.

I have three MFC C++ projects that compile fine when using either v110 or v100. When I switch all three projects to use v110_xp, one of the projects fails to compile.

The errors I get are:

Error C2039: 'SetDefaultDllDirectories' : is not a member of '`global namespace'' c:\program files (x86)\microsoft visual studio 11.0\vc\atlmfc\include\atlcore.h 638 1
Error C2065: 'SetDefaultDllDirectories' : undeclared identifier c:\program files (x86)\microsoft visual studio 11.0\vc\atlmfc\include\atlcore.h 638 1
Error C2065: 'LOAD_LIBRARY_SEARCH_SYSTEM32' : undeclared identifier c:\program files (x86)\microsoft visual studio 11.0\vc\atlmfc\include\atlcore.h 640 1



Details
Sign in to post a comment.
Posted by Microsoft on 2/12/2013 at 3:55 PM
Hello AC374, thank you for openning an Connect report. The issue you are seeing is part of the design for VC++ project engine. It can give you the maximum flexibility and customization. However, it does mean there is a learning curve. This article on MSDN can get you started (http://msdn.microsoft.com/en-us/library/675f1588.aspx). Hope this helps.

The project inherency can be simplified to 3 levels. First, the Project Defaults are the basic settings. The "_USING_V110_SDK71_" are the Project Defaults. The second level is the project wide settings or just project settings. This level affect the entire project. A change to compile option like '/D' will affect all .cpp files. The next level is the per file level settings, or file settings. Changing a value here only affects the individual file.
Each level can inherit from the parent level, the level before it. A file settings can inherit, take the values of, the project settings. The file settings can also append to the project settings or ignore it completely. The project settings, like the file settings, can inherit from project defaults.

In the sample uploaded, each files had file settings that didn't inherit from the parent. This prevent the _USING_V110_SDK71_ flag from propergating to each file.

Hope this helps.

Thanks
Felix Huang
VC++ Project & Build
Posted by AC374 on 12/13/2012 at 1:27 PM
Can you provide any information as to the status of this bug? Is there a workaround or will there be a software update pushed out to address it?
Posted by AC374 on 12/7/2012 at 11:58 AM
I don't see 534486.png attached to this feedback.

Would you please let me know if there are any workarounds or permanent solution for this? Thank you.
Posted by Microsoft on 12/7/2012 at 12:32 AM
Hi AC374, thank you for your response. We have received your project files, VS throwed the same errors in my case as 534486.png shows.
Thank you for submitting feedback on Visual Studio and .NET Framework. Your issue has been routed to the appropriate VS development team for investigation. We will contact you if we require any additional information.
Posted by AC374 on 12/6/2012 at 6:48 AM
I uploaded the project files. You may have to run Visual Studio "as Administrator" to to compile it. Please let me know what you find.
Posted by Microsoft on 12/6/2012 at 2:34 AM
Hello AC374, thanks for your response.
************************************************************
Please zip the file and use "FeedbackID-XXXXXX" as prefix of the file name.
************************************************************
You can use the following workspace to upload the file by IE: https://sftus.one.microsoft.com/choosetransfer.aspx?key=9415c965-6590-4d5f-8331-614ff9c106df
Password: Z1_)G37MTk
Thanks again for your efforts and we look forward to hearing from you.
Microsoft Visual Studio Connect Support Team
Posted by AC374 on 12/4/2012 at 6:11 PM
Is there a way that I can send you the project privately versus posting it here? Thanks.
Posted by Microsoft on 12/4/2012 at 6:00 PM
Thank you for submitting feedback on Visual Studio and .NET Framework. In order to efficiently investigate and reproduce this issue, we are requesting a demo project. Please submit this information to us within 3 business days. We look forward to hearing from you with this information.
Posted by Microsoft on 12/4/2012 at 7:51 AM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(http://support.microsoft.com)
Sign in to post a workaround.
Posted by Eugene Kosmin on 6/26/2014 at 12:30 AM
Make sure there is no another windows SDK in additional includes or somewhere else.
Posted by Wouter_Demuynck on 12/17/2012 at 4:07 AM
I noticed that selecting the v110_xp toolset in the process properties did not automatically enable the _USING_V110_SDK71_ preprocessor flag.

After manually adding the following define at the top of my stdafx.h, the project compiled fine:

#define _USING_V110_SDK71_