A few months ago, we wrote about how to use the Windows Software Development Kit (SDK) for Windows 8 within your Visual Studio 2010 projects. These instructions work great if you are updating just one project, but if you need to use the Windows 8 SDK in many projects, repeating these steps for each project can be tedious.
If you want to use these settings in multiple projects, you can use property sheets to configure these settings once, then reuse the settings in different projects. You can also use these instructions to configure these settings for multiple configurations of the same project.
To get started quickly, we’ve included the content for sample property sheets for x86 and x64 configurations in this blog post, which you can use in most situations. For those of you who want to create the property sheet by using the Property Manager to further customize your build configurations, we’ve also included step by step instructions below.
When creating the property sheet, you may want to select a location that is outside of your project folder; for example, select the folder that contains your solution file. If you’re using source control, you may want to add the property sheet as a solution item to archive it along with your projects and source code.
Note: You will need to create separate files for x86 and for x64. When targeting x64, replace x86 with x64 in the paths listed below.
<?xml version="1.0" encoding="utf-8"?><Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> <ImportGroup Label="PropertySheets" /> <PropertyGroup Label="UserMacros" /> <PropertyGroup> <ExecutablePath>$(VCInstallDir)bin;$(WindowsSdkDir)bin\NETFX 4.0 Tools;$(ProgramFiles)\Windows Kits\8.0\bin\x86;$(VSInstallDir)Common7\Tools\bin;$(VSInstallDir)Common7\tools;$(VSInstallDir)Common7\ide;$(ProgramFiles)\HTML Help Workshop;$(FrameworkSDKDir)\bin;$(MSBuildToolsPath32);$(VSInstallDir);$(SystemRoot)\SysWow64;$(FxCopDir);$(PATH)</ExecutablePath> <IncludePath>$(ProgramFiles)\Windows Kits\8.0\Include\um;$(ProgramFiles)\Windows Kits\8.0\Include\shared;$(VCInstallDir)include;$(VCInstallDir)atlmfc\include;$(FrameworkSDKDir)\include;</IncludePath> <LibraryPath>$(VCInstallDir)lib;$(VCInstallDir)atlmfc\lib;$(ProgramFiles)\Windows Kits\8.0\lib\win8\um\x86;$(FrameworkSDKDir)\lib</LibraryPath> <ExcludePath>$(VCInstallDir)include;$(VCInstallDir)atlmfc\include;$(ProgramFiles)\Windows Kits\8.0\Include\um;$(ProgramFiles)\Windows Kits\8.0\Include\shared;$(FrameworkSDKDir)\include;$(MSBuildToolsPath32);$(VCInstallDir)atlmfc\lib;$(VCInstallDir)lib;</ExcludePath> </PropertyGroup><ItemDefinitionGroup /></Project>
When creating or adding property sheets to your projects, you can choose to select multiple projects or project configurations, in order to add the same sheet to all selected projects at the same time. If you select a project name, rather than a project configuration name, the property sheet will be added to all project configurations of that project. This can save you a lot of time when adding the same settings to many projects in your solution.
Have more questions about using property sheets? Leave us feedback in the comments!
정품은 offle2003 계속 오류는 offle2005에 못찾았습니다.이전에는 비스타에 대해 pc업데이트.폴더.파일에 복사해야함
Thanks
The x64 version of the props file should be:
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="schemas.microsoft.com/.../2003">
<ImportGroup Label="PropertySheets" />
<PropertyGroup Label="UserMacros" />
<PropertyGroup>
<ExecutablePath>$(VCInstallDir)bin\x86_amd64;$(VCInstallDir)bin;$(WindowsSdkDir)bin\NETFX 4.0 Tools;$(ProgramFiles)\Windows Kits\8.0\bin\x64;$(VSInstallDir)Common7\Tools\bin;$(VSInstallDir)Common7\tools;$(VSInstallDir)Common7\ide;$(ProgramFiles)\HTML Help Workshop;$(FrameworkSDKDir)\bin;$(MSBuildToolsPath32);$(VSInstallDir);$(SystemRoot)\SysWow64;$(FxCopDir);$(PATH)</ExecutablePath>
<IncludePath>$(ProgramFiles)\Windows Kits\8.0\Include\um;$(ProgramFiles)\Windows Kits\8.0\Include\shared;$(VCInstallDir)include;$(VCInstallDir)atlmfc\include;$(FrameworkSDKDir)\include;</IncludePath>
<LibraryPath>$(VCInstallDir)lib\amd64;$(VCInstallDir)atlmfc\lib\amd64;$(ProgramFiles)\Windows Kits\8.0\lib\win8\um\x64;$(FrameworkSDKDir)\lib\x64</LibraryPath>
<ExcludePath>$(VCInstallDir)include;$(VCInstallDir)atlmfc\include;$(ProgramFiles)\Windows Kits\8.0\Include\um;$(ProgramFiles)\Windows Kits\8.0\Include\shared;$(FrameworkSDKDir)\include;$(MSBuildToolsPath32);$(VCInstallDir)atlmfc\lib;$(VCInstallDir)lib;</ExcludePath>
</PropertyGroup>
<ItemDefinitionGroup />
</Project>
Actually, minor fix to resolve problem with x64 projects which contain .rc files:
<ExecutablePath>$(VCInstallDir)bin\x86_amd64;$(VCInstallDir)bin;$(WindowsSdkDir)bin\NETFX 4.0 Tools;$(ProgramFiles)\Windows Kits\8.0\bin\x86;$(VSInstallDir)Common7\Tools\bin;$(VSInstallDir)Common7\tools;$(VSInstallDir)Common7\ide;$(ProgramFiles)\HTML Help Workshop;$(FrameworkSDKDir)\bin;$(MSBuildToolsPath32);$(VSInstallDir);$(SystemRoot)\SysWow64;$(FxCopDir);$(PATH)</ExecutablePath>