private void OnCloseConnection() { EventHandler handler = CloseConnection; if (handler != null) handler(this, EventArgs.Empty); }