示例#1
0
 //回复数据的方法
 void SendData(object sender)
 {
     try
     {
         //UdpBussiness.SendData(udp);
         UdpBussiness.SendCommand(udp);
     }
     catch (Exception ex)
     {
     }
 }
示例#2
0
 //回复数据的方法
 void SendData()
 {
     while (true)
     {
         try
         {
             UdpBussiness.SendCommand(udp);
         }
         catch (Exception ex)
         {
             Service.ServiceControl.log.Error(DateTime.Now + ex.ToString());
         }
         Thread.Sleep(500);
     }
 }