protected override void OnStart(string[] args)
 {
     File.Create(AppDomain.CurrentDomain.BaseDirectory + "OnStart.txt");
     PingTest initialPing = new PingTest();
     initialPing.PingCheck();
     timer1.Interval = Properties.Settings.Default.pingTimer;
     timer1.Start();
 }
 private void timer1_Elapsed(object sender, System.Timers.ElapsedEventArgs e)
 {
     PingTest ping = new PingTest();
     ping.PingCheck();
 }