private async void frmMain_Load(object sender, EventArgs e) { Text = $"Demo Manager - {typeof(FrmMain).Assembly.GetName().Version}"; if (string.IsNullOrWhiteSpace(DemoManagerConfiguration.AuthKey)) { using (var frm = new FrmAuthKey()) { frm.ShowDialog(); } } if (string.IsNullOrWhiteSpace(DemoManagerConfiguration.AuthKey)) { MessageBox.Show(this, "You have not entered a Auth Key so the application cannot run - closing now", "No Auth Key", MessageBoxButtons.OK, MessageBoxIcon.Error); Application.Exit(); } localRepositoryView.Repository = Factory.LocalDemoRepository; remoteRepositoryView.Repository = Factory.RemoteDemoRepository; await ReloadRepositories(); }
private async void authKeyToolStripMenuItem_Click(object sender, EventArgs e) { using (var frm = new FrmAuthKey()) { frm.ShowDialog(); } await ReloadRepositories(); }