private void uxCreateNewServer_Click(object sender, EventArgs e) { uxNullServerError.Clear(); var serverForm = new ServerForm(theXML, servers[0]); serverForm.ShowDialog(); reloadData(); }
private void uxEditServerBtn_Click(object sender, EventArgs e) { if (uxServersListBox.SelectedItem == null) { uxNullQueryError.Dispose(); //removes Query error if displayed uxNullServerError.SetError(lblSQLServers, "You need to select a server!"); return; } else { uxNullServerError.Clear(); } var serverForm = new ServerForm(uxServersListBox.SelectedItem.ToString(), servers[uxServersListBox.SelectedIndex].WindowsAuthentication, servers[uxServersListBox.SelectedIndex].ServerCredentials[0], servers[uxServersListBox.SelectedIndex].ServerCredentials[1], theXML, servers[uxServersListBox.SelectedIndex]); serverForm.ShowDialog(); reloadData(); }