private void UpdateFromHltb() { Cursor = Cursors.WaitCursor; HltbPrcDlg dlg = new HltbPrcDlg(); DialogResult res = dlg.ShowDialog(); if (dlg.Error != null) { MessageBox.Show(string.Format(GlobalStrings.DBEditDlg_ErrorWhileUpdatingHltb, dlg.Error.Message), GlobalStrings.DBEditDlg_Error, MessageBoxButtons.OK, MessageBoxIcon.Error); Logger.Error(GlobalStrings.DBEditDlg_Log_ExceptionHltb, dlg.Error.Message); AddStatusMsg(GlobalStrings.DBEditDlg_ErrorUpdatingHltb); } else { if ((res == DialogResult.Cancel) || (res == DialogResult.Abort)) { AddStatusMsg(GlobalStrings.DBEditDlg_CanceledHltbUpdate); } else { AddStatusMsg(string.Format(GlobalStrings.DBEditDlg_Status_UpdatedHltb, dlg.Updated)); UnsavedChanges = true; } } RebuildDisplayList(); Cursor = Cursors.Default; }
private void UpdateFromHltb() { this.Cursor = Cursors.WaitCursor; HltbPrcDlg dlg = new HltbPrcDlg(); DialogResult res = dlg.ShowDialog(); if (dlg.Error != null) { MessageBox.Show(string.Format(GlobalStrings.DBEditDlg_ErrorWhileUpdatingHltb, dlg.Error.Message), GlobalStrings.DBEditDlg_Error, MessageBoxButtons.OK, MessageBoxIcon.Error); Program.Logger.Write(LoggerLevel.Error, GlobalStrings.DBEditDlg_Log_ExceptionHltb, dlg.Error.Message); AddStatusMsg(GlobalStrings.DBEditDlg_ErrorUpdatingHltb); } else { if (res == DialogResult.Cancel || res == DialogResult.Abort) { AddStatusMsg(GlobalStrings.DBEditDlg_CanceledHltbUpdate); } else { AddStatusMsg(string.Format(GlobalStrings.DBEditDlg_Status_UpdatedHltb, dlg.Updated)); UnsavedChanges = true; } } RebuildDisplayList(); this.Cursor = Cursors.Default; }