public Installer1()
{
InitializeComponent(); // TODO: Add any initialization after the InitComponent call
processInstaller = new ServiceProcessInstaller();
serviceInstaller = new ServiceInstaller();
// The services will run under the system account.
processInstaller.Account = ServiceAccount.LocalSystem;
// The services will be started manually.
serviceInstaller.StartType = ServiceStartMode.Automatic; // ServiceName must equal those on ServiceBase derived classes.
serviceInstaller.ServiceName = "MHFTPServer";
serviceInstaller.DisplayName="MYHome个人主页基地FTP服务"; // Add installers to collection. Order is not important.
Installers.Add(serviceInstaller);
Installers.Add(processInstaller);
}
{
InitializeComponent(); // TODO: Add any initialization after the InitComponent call
processInstaller = new ServiceProcessInstaller();
serviceInstaller = new ServiceInstaller();
// The services will run under the system account.
processInstaller.Account = ServiceAccount.LocalSystem;
// The services will be started manually.
serviceInstaller.StartType = ServiceStartMode.Automatic; // ServiceName must equal those on ServiceBase derived classes.
serviceInstaller.ServiceName = "MHFTPServer";
serviceInstaller.DisplayName="MYHome个人主页基地FTP服务"; // Add installers to collection. Order is not important.
Installers.Add(serviceInstaller);
Installers.Add(processInstaller);
}
解决方案 »
免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货