private void frmClient_FormClosed(object sender, FormClosedEventArgs e) { if (client != null) { if (client.Connected) { client.Disconnect(); } client.Dispose(); } }
private void frmClient_FormClosed(object sender, FormClosedEventArgs e) { client.Dispose(); }