예제 #1
0
 public override void enviarMensaje(MensajeOSC msgosc)
 {
     try
     {
         byte[] bytes = null;
         bytes = Encoding.ASCII.GetBytes(msgosc.getMensajeFormatoOSC());
         //   MessageBox.Show(msgosc.getMensajeFormatoOSC()+ "tamaño del buffer: "+ bytes.Length);
         //Send it to the server
         clientSocket.BeginSend(bytes, 0, bytes.Length, SocketFlags.None, new AsyncCallback(OnSend), null);
     }
     catch (Exception)
     {
         MessageBox.Show("Unable to send message to the server.", "ERROR 5 EN Client ");
     }
 }
 public override void enviarMensaje(MensajeOSC msg)
 {
     //msg = new MensajeOSC ( id,  tipo,  confidence, comando);
     MessageBox.Show("The message is: " + msg.getMensajeFormatoOSC());
     puertousb.Write(/*id.ToString()*/ "1");
 }