如何在Visual Studio 2010中将清单文件添加到项目中? [英] How to add a manifest file to a project in visual studio 2010?
问题描述
我正在尝试使用Visual Studio 2010将清单文件添加到项目中,以便将该项目设置为与Windows 7兼容并禁用虚拟化.
I am trying to add a manifest file to a project with Visual Studio 2010, so as to set the project to be compatible with Windows 7 and to disable the virtualization.
问题是,在我想添加新项目时,在Visual Studio 2010中没有可供选择的应用程序清单文件"选项.
The problem is that in my Visual Studio 2010 there is no option "Application Manifest File" to choose when I want to add a new item.
构建项目时,我可以生成清单文件,因为我在链接器中设置了属性.但是我可以修改该文件以向其中添加兼容性属性吗?
I can generate a manifest file when building the project, as I set the property in the Linker to do so. But can I modify that file to add the compatibility property to it?
是否有某种方法可以在项目内部创建清单文件,然后进行构建?还是可以从属性"对话框(清单工具)本身设置兼容性属性?
Is there some way to create the manifest file inside the project and then build it? Or can I set the compatibility property from the Properties dialog (manifest tool) itself?
推荐答案
- 创建所需的清单文件.
- 将其保存为扩展名为
.manifest
的计算机上的某个位置. - 在Visual Studio中右键单击您的项目,然后选择
Add > Existing Item...
- 浏览到清单文件并打开它.
- 构建您的项目.
- Create the manifest file you want.
- Save it somewhere on your computer with a
.manifest
extension. - Right-click your project in Visual Studio, and select
Add > Existing Item...
- Browse to the manifest file and open it.
- Build your project.
这篇关于如何在Visual Studio 2010中将清单文件添加到项目中?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!