21 lines
435 B
C#
21 lines
435 B
C#
using System.ServiceProcess;
|
|||
|
|
|
||
|
|
namespace WindowsService1
|
||
|
|
{
|
||
|
|
internal static class Program
|
||
|
|
{
|
||
|
|
/// <summary>
|
||
|
|
/// 应用程序的主入口点。
|
||
|
|
/// </summary>
|
||
|
|
static void Main()
|
||
|
|
{
|
||
|
|
ServiceBase[] ServicesToRun;
|
||
|
|
ServicesToRun = new ServiceBase[]
|
||
|
|
{
|
||
|
|
new Service1()
|
||
|
|
};
|
||
|
|
ServiceBase.Run(ServicesToRun);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
}
|