private void srvrcnfgrtnMethod() { var dialog = new ServerConfigurationDialog(); if (dialog.ShowDialog() == true) { MessageBox.Show("Connected to " + dialog.ResponseText); } }
private void srvrcnfgrtnBTTN_Click(object sender, RoutedEventArgs e) { if (UserLevelValue.Equals("Admin")) { var dialog = new ServerConfigurationDialog(); if (dialog.ShowDialog() == true) { srvrcnfgrtnTBNM.Text = dialog.ResponseText; } } else { MessageBox.Show("You must logged in as admin."); } }