C# 服务部署 报System.InvalidOperationException异常该怎么处理?

kangkai2004163 2012-12-19 03:46:35

Running a transacted installation.

Beginning the Install phase of the installation.
See the contents of the log file for the D:\DonetProject\LH.CPCD_Check\LH.CPCD_Check.exe assembly's progress.
The file is located at D:\DonetProject\LH.CPCD_Check\LH.CPCD_Check.InstallLog.

An exception occurred 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.

The Rollback phase of the installation is beginning.
See the contents of the log file for the D:\DonetProject\LH.CPCD_Check\LH.CPCD_Check.exe assembly's progress.
The file is located at D:\DonetProject\LH.CPCD_Check\LH.CPCD_Check.InstallLog.

The Rollback phase completed successfully.

The transacted install has completed.


环境是VS2010 WIN7
是远程部署在服务器上的。使用的管理员账号
...全文
811 1 打赏 收藏 转发到动态 举报
写回复
用AI写文章
1 条回复
切换为时间正序
请发表友善的回复…
发表回复
zhongheijituan 2015-05-06
  • 打赏
  • 举报
回复
遇到过相同问题,尤其是在64位机器上面,找到installutil,设置属性中以管理员身份运行,勾选,然后从新运行安装,就可以了

110,571

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧