【发布时间】:2009-12-20 11:26:39
【问题描述】:
我正在尝试在 Windows Server 2003 上启动 Windows 服务 从 ASP.NET 页面:
第35行代码为:
32. Dim controller As New ServiceController
33. controller.MachineName = System.Environment.MachineName
34. controller.ServiceName = "WindowsServiceRealName"
35. controller.Start()
错误代码是
System.InvalidOperationException:无法在计算机“DARWIN”上打开 WindowsServiceRealName 服务。 ---> System.ComponentModel.Win32Exception:访问被拒绝---内部异常堆栈跟踪结束---在 System.ServiceProcess.ServiceController.GetServiceHandle(Int32 desiredAccess) 在 System.ServiceProcess.ServiceController.Start(String[] args ) 在 System.ServiceProcess.ServiceController.Start() at AfconParking.Import.StartService() 在 E:\ProjectsNet\AfconParking\AfconParking\system\Import.aspx.vb:line 35
【问题讨论】:
标签: asp.net windows-server-2003