我无法安装windows服务

本文关键字:windows 服务 安装 | 更新日期: 2023-09-27 18:25:58

我创建了一个windows服务。它基本上什么都没有。目的只是注册。在构建项目后。我已经启动了VS2013的开发者命令提示符,并键入了以下命令

C:'Users'xxx'Documents'visual studio 2013'Projects'WindowsService3'WindowsService3'bin'Debug WindowsService3.exe

我收到这个消息

Exception occurred while initializing the installation:
System.IO.FileNotFoundException: Could not load file or assembly 'file:///C:'Use
rs'xxx'Documents'visual' or one of its dependencies. Sytem coudnt find specified..........

然后我尝试了sc.exe,但没有任何变化。这是消息

SC]CreateService失败-487:如这里

我做错了什么

我无法安装windows服务

尝试C:'Windows'Microsoft.NET'Framework64'v4.0.30319'InstallUtil.exe /LogToConsole=true "Full path to exe goes there"