Esempio n. 1
0
 private void RaiseDataReceived(ReceivedDataArgs args)
 {
     if (DataReceivedEvent != null)
     {
         DataReceivedEvent(this, args);
     }
 }
Esempio n. 2
0
 void receiver_DataReceivedEvent(object sender, ReceivedDataArgs args)
 {
     Console.WriteLine("Received message from [{0}:{1}]:" +
                       Environment.NewLine + "{2}",
                       args.ipAddress.ToString(),
                       args.Port.ToString(),
                       "Length: " +
                       args.ReceivedBytes.Length,
                       Environment.NewLine + "----------");
 }