注册和卸载window service

自己开发的windows service编译之后会生成的exe文件,不能直接运行,必须通过工具注册进系统的Service。

使用cmd运行命令执行注册和卸载:

注册service:

C:WindowsMicrosoft.NETFrameworkv4.0.30319>installutil D:MyService.exe

卸载Service:

C:WindowsMicrosoft.NETFrameworkv4.0.30319>installutil /u D:MyService.exe

原文地址:https://www.cnblogs.com/yuejin/p/3736837.html