/// /// <summary> /// 登録ボタンを押下時データベースにInsertする /// </summary> public void Save() { if (ErrorCheck()) { if (ExchangeLabel.Text != ExchangeMoney.Text) { trrnbl.ShowMessage("E181"); ExchangeCount.Focus(); } else { if (trrnbl.ShowMessage("Q101") == DialogResult.Yes) { DataTable dt = new DataTable(); dt = trrnbl.SimpleSelect1("70", ChangeDate.Replace("/", "-"), storeCD); if (dt.Rows.Count > 0) { trrnbl.ShowMessage("E252"); } valid = false; mre = DepositHistoryEnity(); if (trrnbl.TempoRegiRyougaeNyuuryoku_Insert_Update(mre)) { trrnbl.ShowMessage("I101"); RunConsole(); //exeRun ExchangeDenomination.SelectedValue = "-1"; ExchangeMoney.Clear(); ExchangeCount.Clear(); ExchangeLabel.Text = ""; Remark.Clear(); ExchangeMoney.Focus(); } else { trrnbl.ShowMessage("S001"); } } else { PreviousCtrl.Focus(); //Remark.Focus(); } } } }
/// <summary> /// 登録ボタンを押下時データベースにInsertする /// </summary> public void Save() { if (ErrorCheck()) { { if (trtjb.ShowMessage("Q101") == DialogResult.Yes) { DataTable dt = new DataTable(); dt = trtjb.SimpleSelect1("70", ChangeDate.Replace("/", "-"), storeCD, txtDate.Text); if (dt.Rows.Count > 0) { trtjb.ShowMessage("E252"); } mre = DepositHistoryEnity(); if (trtjb.TempoRegiTsurisenJyunbi_Insert_Update(mre)) { trtjb.ShowMessage("I101"); RunConsole(); txtDate.Clear(); DepositGaku.Clear(); Remark.Clear(); txtDate.Focus(); } else { trtjb.ShowMessage("S001"); } } else { DepositGaku.Focus(); } } } }