我有 Windows 8 我有一个用 c# 和 Visual Studio 2013 编写的 Windows 应用程序,并且想要安装这个应用程序。
我打开命令提示符写:
c:\..\instalutil.exe c:\projectfolder\filename.exe
在我运行此代码后,它给了我错误:
An exception occured during the Install phase.
System.InvalidOperationException: Cannot open Service Control Manager on computer '.'. This operation might require other privileges.
The inner exception System.ComponentModel.Win32Exception was thrown with the following error message: Access is denied.
这是我的电脑,我不知道为什么它需要访问权限?而且我不知道如何给予正确的特权。
我也将我的 sercviceProcessInstaller Account 属性更改为 LocalSystem 并尝试使用 LocalService 但它们都给了我同样的错误。
我应该怎么做才能给予正确的特权?