public void StartListen() { UdpState s = new UdpState(); s.E = EndPoint; s.U = udpClient; udpClient.BeginReceive(new AsyncCallback(ReceiveCallBack), s); }
public void StartListening() { stopListening = false; UdpState state = new UdpState(); state.E = receiveEndPoint; state.U = udpClient; udpClient.BeginReceive(new AsyncCallback(ReceiveListenCallBack), state); }