private void btnCancelVoidRequest_Click(object sender, EventArgs e) { if (XtraMessageBox.Show("Are you sure you want to cancel the void request?", "Confirmation", MessageBoxButtons.YesNo, MessageBoxIcon.Question) == DialogResult.Yes) { MyGeneration.dOOdads.TransactionMgr mgr = MyGeneration.dOOdads.TransactionMgr.ThreadTransactionMgr(); try { mgr.BeginTransaction(); BLL.Issue stv = new BLL.Issue(); stv.LoadByPrimaryKey(_activeSTVID); stv.CancelVoidRequest(CurrentContext.UserId); mgr.CommitTransaction(); this.LogActivity("Cancel-Void", _activeSTVID); XtraMessageBox.Show("Void request cancelled!", "Success", MessageBoxButtons.OK, MessageBoxIcon.Information); } catch (Exception exp) { mgr.RollbackTransaction(); XtraMessageBox.Show("System couldn't perform the requested action, Please contact administrator", "Error", MessageBoxButtons.OK, MessageBoxIcon.Error); ErrorHandler.Handle(exp); } BindUnconfirmedIssues(); gridUndispatchedIssueDetails.DataSource = null; } }