如何安装Windows服务应用程序?
问题描述:
我使用C#开发了一个服务应用程序。该程序运行正常,但我安装它有问题。
我尝试过:
如果我尝试启动' InstallUtil.exe '以便我可以使用它来安装它,' InstallUtil.exe '将运行并自行关闭自动。此外,如果我尝试使用 cmd 运行
I developed a service application using C#. The program run fine but i have problem installing it.
What I have tried:
If I try to start 'InstallUtil.exe' so that i can use it to install it, the 'InstallUtil.exe' will run and close itself automatically. Also if i try to run the
'InstallUtil.exe'
,它将显示一个消息框,显示Windows不能找到'InstallUtil'。确保正确输入名称然后重试。
using cmd it will show a messagebox showing "Windows cannot find 'InstallUtil'. make sure you type the name correctly and try again."
答
虽然本文的主题不同,但它包含了一个代码。自助安装服务...
Windows服务托管多个WCF服务 [ ^ ]
While the exact subject of this article is different, it contains the code for a self installing service...
Windows Service to Host Multiple WCF Services[^]