安装脚本
%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe D:\liuyl\WeiXinService\WindowsService.exe
net start WXService
sc config WXService start= auto
WXService 是服务的名称
卸载脚本
%SystemRoot%\Microsoft.NET\Framework\v4.0.30319\InstallUtil.exe -u D:\liuyl\WeiXinService\WindowsService.exe