private void mnuBackup_Click(object sender, EventArgs e) { BioSeqBackup frm = new BioSeqBackup(); DialogResult rc = frm.ShowDialog(); if (rc == DialogResult.OK) // then the config has the specs { Cursor.Current = Cursors.WaitCursor; WSLProxyResponse WSLResponse = ServiceCallHelper.BackupDatabase(AppConfigHelper.LoggedOnUser, AppConfigHelper.JsonConfig()); // Parameters are in appsettings. ServiceCallHelper.LoadConfig(AppConfigHelper.LoggedOnUser); // To retrieve StandardOutput and LastError. Cursor.Current = Cursors.Default; if (WSLResponse.ExitCode == 0) { RefreshVersionInformation(AppConfigHelper.seqdbConfig.seqDBs[AppConfigHelper.seqdbConfig.LastDBSelected]); MessageBox.Show(AppConfigHelper.StandardOutput + Environment.NewLine + "Backup successfully completed.", "Success", MessageBoxButtons.OK); // Refresh backup version display. } else { MessageBox.Show("Backup completed with error code " + WSLResponse.ExitCode.ToString() + "." + Environment.NewLine + Environment.NewLine + AppConfigHelper.StandardOutput + Environment.NewLine + AppConfigHelper.LastError, "Error", MessageBoxButtons.OK); } } }