VS 2010安装程序快捷方式文件显示不以管理员身份运行选项 [英] VS 2010 setup shortcut file not shows Run as Administrator option

查看:995
本文介绍了VS 2010安装程序快捷方式文件显示不以管理员身份运行选项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我创建了一个安装项目在VS2010(C#)一个Windows应用程序。我已经添加应用程序文件夹中项目的主输出和它的快捷方式到桌面文件夹中。在安装设置完成后,桌面快捷方式包含exe文件没有显示在鼠标选择右键以管理员身份运行。

I have created a setup project for a windows application in VS2010 (C#). I have added project primary output in application folder and its shortcut to desktop folder. After installing the setup, the desktop contain shortcut exe file not shows "Run as Administrator" option on mouse right click.

我已经看到在堆栈溢出一些职位来设置清单文件中的标签是这样的:

I have seen some post in stack overflow to set the tag in manifest file like this :

 <requestedExecutionLevel level="requireAdministrator" uiAccess="true"/>

但我找不到我的应用程序的任何清单文件。其中,它的位置?如何attcah这个清单设置项目?

But I couldn't find any manifest file in my app. where its location? How to attcah this manifest to setup project?

请帮忙。

推荐答案

添加一个清单文件到您的程序。

Add a manifest file to your program.

点击项目 - > 添加新项 - >添加应用程序清单文件

Click Project -> Add new item -> add Application Manifest File

在默认情况下你会看到有:

By default you will see there:

&LT; requestedExecutionLevel水平=asInvokeruiAccess =真/&GT;

请务必将其替换为:

&LT; requestedExecutionLevel水平=requireAdministratoruiAccess =真/&GT;

这篇关于VS 2010安装程序快捷方式文件显示不以管理员身份运行选项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
相关文章
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆