private void DependencyExplorer_FormClosed(object sender, FormClosedEventArgs e) { Database database; // Get selected database from DatabaseComboBox database = (Database)(this.DatabasesComboBox.SelectedItem); // Stop receiving events if (database != null) { database.Events.StopEvents(); // Unsubscribe to table events database.Events.UnsubscribeAllEvents(); } SqlServerSelection = null; refreshDbTables = null; }
private void DependencyExplorer_Load(object sender, EventArgs e) { this.DatabasesComboBox.Enabled = false; this.DatabasesComboBox.DisplayMember = Properties.Resources.Name; this.DatabasesComboBox.Text = Properties.Resources.SelectDatabase; this.TableListView.View = System.Windows.Forms.View.Details; this.TableListView.Columns.Add(Properties.Resources.Name, 120, HorizontalAlignment.Left); this.TableListView.Columns.Add(Properties.Resources.Schema, 120, HorizontalAlignment.Left); this.TableListView.Columns.Add(Properties.Resources.CreateDate, 120, HorizontalAlignment.Left); this.TableListView.Columns.Add(Properties.Resources.RowCount, 120, HorizontalAlignment.Right); this.TableListView.Columns.Add(Properties.Resources.DataSize, 120, HorizontalAlignment.Right); this.TableListView.Columns.Add(Properties.Resources.Urn, 120, HorizontalAlignment.Left); this.TableListView.GridLines = true; this.TableListView.FullRowSelect = true; this.TableListView.Items.Clear(); this.StatusBar.Text = Properties.Resources.NotConnected; this.ConnectToServer(); refreshDbTables = new RefreshDatabaseTables(RefreshTables); }
private void DependencyExplorer_Load(object sender, EventArgs e) { this.DatabasesComboBox.Enabled = false; this.DatabasesComboBox.DisplayMember = Properties.Resources.Name; this.DatabasesComboBox.Text = Properties.Resources.SelectDatabase; this.TableListView.View = System.Windows.Forms.View.Details; this.TableListView.Columns.Add(Properties.Resources.Name, 120, HorizontalAlignment.Left); this.TableListView.Columns.Add(Properties.Resources.Schema, 120, HorizontalAlignment.Left); this.TableListView.Columns.Add(Properties.Resources.CreateDate, 120, HorizontalAlignment.Left); this.TableListView.Columns.Add(Properties.Resources.RowCount, 120, HorizontalAlignment.Right); this.TableListView.Columns.Add(Properties.Resources.DataSize, 120, HorizontalAlignment.Right); this.TableListView.Columns.Add(Properties.Resources.Urn, 120, HorizontalAlignment.Left); this.TableListView.GridLines = true; this.TableListView.FullRowSelect = true; this.TableListView.Items.Clear(); this.StatusBar.Text = Properties.Resources.NotConnected; this.ConnectToServer(); refreshDbTables = new RefreshDatabaseTables(RefreshTables); }
private void DependencyExplorer_FormClosed(object sender, FormClosedEventArgs e) { Database database; // Get selected database from DatabaseComboBox database = (Database)(this.DatabasesComboBox.SelectedItem); // Stop receiving events if (database != null) { database.Events.StopEvents(); // Unsubscribe to table events database.Events.UnsubscribeAllEvents(); } SqlServerSelection = null; refreshDbTables = null; }