protected override void ExecuteCore(SelectedItemCollection selection) { AddServerDialog dialog = new AddServerDialog(null, false); dialog.CachePopulated += dialog_CachePopulated; dialog.Show(Parent); }
public void Start() { AddServerDialog dialog = new AddServerDialog(_connection, false); dialog.FormClosing += formClosing; dialog.Show(_parentForm); }
private static bool PromptForNewPassword(IXenConnection connection, string oldPassword) { bool result = false; Program.Invoke(Program.MainWindow, () => { // show an altered version of the add server dialog with the hostname greyed out using (var dialog = new AddServerDialog(connection, true)) result = dialog.ShowDialog(Program.MainWindow) == DialogResult.OK; }); return(result); }