36 lines
839 B
C#
36 lines
839 B
C#
using System;
|
|
using System.Collections.Generic;
|
|
using System.ComponentModel;
|
|
using System.Configuration;
|
|
using System.Data;
|
|
using System.Diagnostics;
|
|
using System.IO;
|
|
using System.Linq;
|
|
using System.ServiceProcess;
|
|
using System.Text;
|
|
using System.Threading.Tasks;
|
|
using System.Timers;
|
|
|
|
namespace solarWinService
|
|
{
|
|
internal static class Program
|
|
{
|
|
//從App.config取出檔案路徑及名稱
|
|
//private readonly string _FilePath = ConfigurationManager.AppSettings["FilePath"];
|
|
|
|
/// <summary>
|
|
/// 應用程式的主要進入點。
|
|
/// </summary>
|
|
static void Main()
|
|
{
|
|
ServiceBase[] ServicesToRun;
|
|
ServicesToRun = new ServiceBase[]
|
|
{
|
|
new Service1()
|
|
};
|
|
ServiceBase.Run(ServicesToRun);
|
|
}
|
|
|
|
}
|
|
}
|