Example #1
0
 private void button2_Click(object sender, EventArgs e)
 {
     // 断开连接
     fastEnet.ConnectClose( );
     button2.Enabled = false;
     button1.Enabled = true;
     panel2.Enabled  = false;
 }
Example #2
0
        public void Disconnection()
        {
            try
            {
                fastEnet.ConnectClose();

                IsConnected = false;
            }
            catch (SocketException ex)
            {
                EventscadaException?.Invoke(this.GetType().Name, ex.Message);
            }
        }
Example #3
0
        public bool Disconnection()
        {
            try
            {
                fastEnet.ConnectClose();

                IsConnected = false;
                return(IsConnected);
            }
            catch (SocketException ex)
            {
                EventscadaException?.Invoke(GetType().Name, ex.Message);
                return(IsConnected);
            }
        }