protected void ddlAccNo_SelectedIndexChanged(object sender, EventArgs e) { if (ddlAccNo.SelectedIndex != 0) { Int64 accno = Converter.GetLong(ddlAccNo.SelectedValue); A2ZACCOUNTDTO getDTO = (A2ZACCOUNTDTO.GetInfoAccNo(accno)); if (getDTO.AccNo > 0) { txtCurrentBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccBalance)); txtPrincipal.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccPrincipal)); txtIntBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccInterest)); txtInterestRate.Text = Converter.GetString(String.Format("{0:0,0.000}", getDTO.AccIntRate)); lblCurrencyCode.Text = Converter.GetString(getDTO.AccCurrency); int code = Converter.GetInteger(lblCurrencyCode.Text); A2ZCURRENCYDTO get1DTO = (A2ZCURRENCYDTO.GetInformation(code)); if (get1DTO.CurrencyCode > 0) { txtCurrency.Text = Converter.GetString(get1DTO.CurrencyName); } } } }
protected void BtnVerify_Click(object sender, EventArgs e) { Button b = (Button)sender; GridViewRow r = (GridViewRow)b.NamingContainer; Label accno = (Label)gvAccInfo.Rows[r.RowIndex].Cells[4].FindControl("lblaccno"); A2ZACCOUNTDTO objDTO = new A2ZACCOUNTDTO(); objDTO.AccNo = Converter.GetLong(accno.Text); objDTO.AccStatus = Converter.GetInteger(1); int roweffect = A2ZACCOUNTDTO.UpdateAccStatus(objDTO); if (roweffect > 0) { gvVerify(); string CheckQuery = "SELECT lTrim(str(dbo.A2ZACCOUNT.CuType)+lTrim(str(dbo.A2ZACCOUNT.CuNo))) As CuNo,dbo.A2ZACCOUNT.MemNo,dbo.A2ZMEMBER.MemName,dbo.A2ZACCOUNT.AccNo FROM A2ZACCOUNT INNER JOIN dbo.A2ZMEMBER ON dbo.A2ZACCOUNT.CuType = dbo.A2ZMEMBER.CuType AND dbo.A2ZACCOUNT.CuNo = dbo.A2ZMEMBER.CuNo AND dbo.A2ZACCOUNT.MemNo = dbo.A2ZMEMBER.MemNo Where AccStatus=91"; DataTable dt = new DataTable(); dt = CommonManager.Instance.GetDataTableByQuery(CheckQuery, "A2ZCSMCUS"); if (dt.Rows.Count <= 0) { DivGridViewCancle.Visible = false; lblmsg1.Visible = true; lblmsg2.Visible = true; } } }
protected void ddlAccNo_SelectedIndexChanged(object sender, EventArgs e) { txtAccNo.Text = ddlAccNo.SelectedValue; Int64 accno = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO getDTO = (A2ZACCOUNTDTO.GetInfoAccNo(accno)); if (getDTO.AccNo > 0) { CtrlAccType.Text = Converter.GetString(getDTO.AccType); lblLdgCurrencyCode.Text = Converter.GetString(getDTO.AccCurrency); int code = Converter.GetInteger(lblLdgCurrencyCode.Text); A2ZCURRENCYDTO get1DTO = (A2ZCURRENCYDTO.GetInformation(code)); if (get1DTO.CurrencyCode > 0) { txtLedgerCurrency.Text = Converter.GetString(get1DTO.CurrencyName); txtledgerBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccBalance)) + " " + txtLedgerCurrency.Text; txtAmount.Focus(); //ddlCurrency.SelectedValue = lblLdgCurrencyCode.Text; //CashDropdown(); } } }
protected void ddlAccType_SelectedIndexChanged(object sender, EventArgs e) { if (ddlAccType.SelectedValue == "-Select-") { txtAccType.Text = string.Empty; txtAccType.Focus(); } if (ddlAccType.SelectedValue != "-Select-") { Int16 MainCode = Converter.GetSmallInteger(ddlAccType.SelectedValue); A2ZACCTYPEDTO getDTO = (A2ZACCTYPEDTO.GetInformation(MainCode)); if (getDTO.AccTypeCode > 0) { txtAccType.Text = Converter.GetString(getDTO.AccTypeCode); } else { txtAccType.Text = string.Empty; } // string qry = "SELECT AccNo,AccNo FROM A2ZACCOUNT WHERE AccType = '" + txtAccType.Text + "'"; // DataTable dt = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry, "A2ZCSMCUS"); // if (dt.Rows.Count > 0) Int16 Acctype = Converter.GetSmallInteger(txtAccType.Text); Int64 AccNumber = Converter.GetLong(txtAccNo.Text); Int16 CuType = 0; int CUnumber = 0; int MemNumber = Converter.GetInteger(txtMemNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInformation(Acctype, AccNumber, CuType, CUnumber, MemNumber)); if (accgetDTO.a > 0) { txtAccNo.Text = Converter.GetString(accgetDTO.AccNo); } else { String csname1 = "PopupScript"; Type cstype = GetType(); ClientScriptManager cs = Page.ClientScript; if (!cs.IsStartupScriptRegistered(cstype, csname1)) { String cstext1 = "alert('Account Does Not Exist');"; cs.RegisterStartupScript(cstype, csname1, cstext1, true); } txtAccType.Text = string.Empty; txtAccType.Focus(); return; } } }
private void AccDropdown() { lblMsgFlag.Text = "0"; string sqlquery = "SELECT AccType,AccNo from A2ZACCOUNT WHERE AccPartyNo = '" + txtPartyCode.Text + "' AND AccCurrency = '" + ddlCurrency.SelectedValue + "' AND AccStatus = 1"; ddlAccNo = DataAccessLayer.BLL.CommonManager.Instance.FillDropDownList(sqlquery, ddlAccNo, "A2ZACGMS"); string qry = "SELECT AccType,AccNo,AccCurrency FROM A2ZACCOUNT where AccPartyNo='" + txtPartyCode.Text + "' AND AccCurrency = '" + ddlCurrency.SelectedValue + "' AND AccStatus = 1"; DataTable dt = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry, "A2ZACGMS"); int totrec = dt.Rows.Count; if (totrec == 1) { CtrlAccType.Text = Converter.GetString(dt.Rows[0]["AccType"]); txtAccNo.Text = Converter.GetString(dt.Rows[0]["AccNo"]); lblLdgCurrencyCode.Text = Converter.GetString(dt.Rows[0]["AccCurrency"]); Int64 accno = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO getDTO = (A2ZACCOUNTDTO.GetInfoAccNo(accno)); if (getDTO.AccNo > 0) { int code = Converter.GetInteger(lblLdgCurrencyCode.Text); A2ZCURRENCYDTO get1DTO = (A2ZCURRENCYDTO.GetInformation(code)); if (get1DTO.CurrencyCode > 0) { txtLedgerCurrency.Text = Converter.GetString(get1DTO.CurrencyName); txtledgerBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccBalance)) + " " + txtLedgerCurrency.Text; txtAmount.Focus(); //ddlCurrency.SelectedValue = lblLdgCurrencyCode.Text; //CashDropdown(); } } txtAccNo.Visible = true; ddlAccNo.Visible = false; } else if (totrec > 1) { txtAccNo.Visible = false; ddlAccNo.Visible = true; } else { lblMsgFlag.Text = "1"; } }
protected void ddlCash_SelectedIndexChanged(object sender, EventArgs e) { Int64 keyno = Converter.GetLong(ddlCash.SelectedValue); A2ZACCOUNTDTO get1DTO = (A2ZACCOUNTDTO.GetInfoAccNo(keyno)); if (get1DTO.AccNo > 0) { txtCashBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", get1DTO.AccBalance)) + " " + txtLedgerCurrency.Text; } }
protected void ddlToCash_SelectedIndexChanged(object sender, EventArgs e) { Int64 keyno = Converter.GetLong(ddlToCash.SelectedValue); A2ZACCOUNTDTO get1DTO = (A2ZACCOUNTDTO.GetInfoAccNo(keyno)); if (get1DTO.AccNo > 0) { txtToBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", get1DTO.AccBalance)); txtAmt.Focus(); } }
protected void AccGetInfo() { try { Int64 AccNumber = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a == 0 || accgetDTO.AccStatus > 97) { txtAccType.Text = string.Empty; ddlAcType.SelectedIndex = 0; lblAccTitle.Text = string.Empty; lblCuName.Text = string.Empty; lblMemName.Text = string.Empty; txtCreditUNo.Text = string.Empty; txtMemNo.Text = string.Empty; txtAccNo.Text = string.Empty; txtAccNo.Focus(); return; } else { txtAccType.Text = Converter.GetString(accgetDTO.AccType); if (txtAccType.Text != "0") { ddlAcType.SelectedValue = txtAccType.Text; } lblCuType.Text = Converter.GetString(accgetDTO.CuType); lblCuNo.Text = Converter.GetString(accgetDTO.CuNo); txtCreditUNo.Text = (lblCuType.Text + "-" + lblCuNo.Text); txtMemNo.Text = Converter.GetString(accgetDTO.MemberNo); lblMemName.Text = Converter.GetString(accgetDTO.MemberName); lblcls.Text = Converter.GetString(accgetDTO.AccAtyClass); Int16 CType = Converter.GetSmallInteger(lblCuType.Text); int CNo = Converter.GetInteger(lblCuNo.Text); A2ZCUNIONDTO get5DTO = (A2ZCUNIONDTO.GetInformation(CType, CNo)); if (get5DTO.NoRecord > 0) { lblCuName.Text = Converter.GetString(get5DTO.CreditUnionName); } } } catch (Exception ex) { ClearText(); Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.AccGetInfo Problem');</script>"); //throw ex; } }
private void LoanAccDropdown(int Atype) { lblMsgFlag.Text = "0"; string sqlquery = "SELECT AccNo,CONCAT(AccNo,'-',A2ZCURRENCY.CurrencyName) AS AccNum from A2ZACCOUNT inner join A2ZCURRENCY on A2ZCURRENCY.CurrencyCode=A2ZACCOUNT.AccCurrency WHERE AccType = " + Atype + " AND AccPartyNo = " + txtPartyCode.Text + " AND AccCurrency = " + ddlCurrency.SelectedValue + " AND AccStatus = 1 AND AccLoanAmt > 0"; ddlAccNo = DataAccessLayer.BLL.CommonManager.Instance.FillDropDownList(sqlquery, ddlAccNo, "A2ZACGMS"); string qry = "SELECT AccNo,AccNo FROM A2ZACCOUNT where AccPartyNo='" + txtPartyCode.Text + "' and AccType='" + ddlLoanType.SelectedValue + "' AND AccCurrency = " + ddlCurrency.SelectedValue + " AND AccStatus = 1 AND AccLoanAmt > 0"; DataTable dt = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry, "A2ZACGMS"); int totrec = dt.Rows.Count; if (totrec == 1) { txtAccNo.Text = Converter.GetString(dt.Rows[0]["AccNo"]); Int64 accno = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO getDTO = (A2ZACCOUNTDTO.GetInfoAccNo(accno)); if (getDTO.AccNo > 0) { txtCurrentBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccBalance)); txtInterestRate.Text = Converter.GetString(String.Format("{0:0,0.000}", getDTO.AccIntRate)); lblCurrencyCode.Text = Converter.GetString(getDTO.AccCurrency); //int code = Converter.GetInteger(lblCurrencyCode.Text); //A2ZCURRENCYDTO get1DTO = (A2ZCURRENCYDTO.GetInformation(code)); //if (get1DTO.CurrencyCode > 0) //{ // txtCurrency.Text = Converter.GetString(get1DTO.CurrencyName); //} } txtAccNo.Visible = true; ddlAccNo.Visible = false; return; } else if (totrec > 1) { txtAccNo.Visible = false; ddlAccNo.Visible = true; return; } else { lblMsgFlag.Text = "1"; ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Loan Account Not Found');", true); return; } }
protected void txtMemNo_TextChanged(object sender, EventArgs e) { A2ZACCOUNTDTO GetAccount = new A2ZACCOUNTDTO(); Int16 CuType = Converter.GetSmallInteger(lblCuType.Text); int AccType = Converter.GetInteger(ddlAcType.SelectedValue); int CreditNo = Converter.GetInteger(lblCuNo.Text); int MemberNo = Converter.GetInteger(txtMemNo.Text); GetAccount = (A2ZACCOUNTDTO.GetInfo(AccType, CuType, CreditNo, MemberNo)); if (GetAccount.AccNo > 0 && GetAccount.AccStatus < 98) { txtAccNo.Text = Converter.GetString(GetAccount.AccNo); } else { txtAccNo.Text = string.Empty; txtMemNo.Text = string.Empty; txtMemNo.Focus(); return; } A2ZMEMBERDTO getDTO = new A2ZMEMBERDTO(); if (chkOldSearch.Checked == true) { int MemNumber = Converter.GetInteger(txtMemNo.Text); int CuNumber = Converter.GetInteger(hdnCuNumber.Text); getDTO = (A2ZMEMBERDTO.GetInfoOldMember(CuNumber, MemNumber)); } else { Int16 CUType = Converter.GetSmallInteger(lblCuType.Text); int CUNo = Converter.GetInteger(lblCuNo.Text); int MNo = Converter.GetInteger(txtMemNo.Text); getDTO = (A2ZMEMBERDTO.GetInformation(CUType, CUNo, MNo)); } if (getDTO.NoRecord > 0) { lblMemName.Text = Converter.GetString(getDTO.MemberName); txtAmount.Focus(); } else { lblMemName.Text = string.Empty; txtMemNo.Focus(); } }
protected void txtAccType_TextChanged(object sender, EventArgs e) { if (txtAccType.Text != string.Empty) { Int16 MainCode = Converter.GetSmallInteger(txtAccType.Text); A2ZACCTYPEDTO getDTO = (A2ZACCTYPEDTO.GetInformation(MainCode)); if (getDTO.AccTypeCode > 0) { ddlAccType.SelectedValue = Converter.GetString(getDTO.AccTypeCode); } else { ddlAccType.SelectedValue = "-Select-"; } Int16 Acctype = Converter.GetSmallInteger(txtAccType.Text); Int64 AccNumber = Converter.GetLong(txtAccNo.Text); Int16 CuType = 0; int CUnumber = 0; int MemNumber = Converter.GetInteger(txtMemNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInformation(Acctype, AccNumber, CuType, CUnumber, MemNumber)); if (accgetDTO.a > 0) { txtAccNo.Text = Converter.GetString(accgetDTO.AccNo); } else { String csname1 = "PopupScript"; Type cstype = GetType(); ClientScriptManager cs = Page.ClientScript; if (!cs.IsStartupScriptRegistered(cstype, csname1)) { String cstext1 = "alert('Account Does Not Exist');"; cs.RegisterStartupScript(cstype, csname1, cstext1, true); } txtAccType.Text = string.Empty; txtAccType.Focus(); return; } } }
protected void GetInfo() { try { Int64 AccNumber = Converter.GetLong(txtAccountNo.Text); A2ZACCOUNTDTO getDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (getDTO.a > 0) { CtrlAccStatus.Text = Converter.GetString(getDTO.AccStatus); CtrlAccType.Text = Converter.GetString(getDTO.AccType); if (CtrlAccStatus.Text == "98") { txtAccountNo.Text = string.Empty; txtAccountNo.Focus(); AccTransferedMSG(); return; } //Int16 AccStat = Converter.GetSmallInteger(CtrlAccStatus.Text); //A2ZACCSTATUSDTO get3DTO = (A2ZACCSTATUSDTO.GetInformation(AccStat)); //if (get3DTO.AccStatusCode > 0) //{ // txtstat.Text = Converter.GetString(get3DTO.AccStatusDescription); //} txtPartyCode.Text = Converter.GetString(getDTO.AccPartyNo); txtAccType.Text = Converter.GetString(CtrlAccType.Text); ddlAccType.SelectedValue = Converter.GetString(CtrlAccType.Text); } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetInfo Problem');</script>"); } }
protected void ddlCurrency_SelectedIndexChanged(object sender, EventArgs e) { if (ddlPartyName.SelectedIndex != 0) { string qry = "SELECT AccType,AccNo,AccCurrency FROM A2ZACCOUNT where AccPartyNo='" + ddlPartyName.SelectedValue + "' AND AccCurrency = '" + ddlCurrency.SelectedValue + "' AND AccStatus = 1"; DataTable dt = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry, "A2ZACGMS"); int totrec = dt.Rows.Count; if (totrec > 0) { lblPartyAccType.Text = Converter.GetString(dt.Rows[0]["AccType"]); lblPartyAccno.Text = Converter.GetString(dt.Rows[0]["AccNo"]); Int64 accno = Converter.GetLong(lblPartyAccno.Text); A2ZACCOUNTDTO AccDTO = (A2ZACCOUNTDTO.GetInfoAccNo(accno)); if (AccDTO.AccNo > 0) { txtCurrentBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", AccDTO.AccBalance)); lblCurrencyCode.Text = Converter.GetString(AccDTO.AccCurrency); } } } }
public void GetAccInfo() { try { Int64 AccNumber = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a == 0) { InvalidAccountNoMSG(); txtAccNo.Text = string.Empty; txtAccNo.Focus(); return; } else { lblAtyClass.Text = Converter.GetString(accgetDTO.AccAtyClass); if (lblAtyClass.Text != "2") { txtAccNo.Text = string.Empty; txtAccNo.Focus(); ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Invalid Account No.');", true); return; } CtrlAccType.Text = txtAccNo.Text.Substring(0, 2); ValidationProcess(); } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetAccInfo Problem');</script>"); //throw ex; } }
protected void BtnGenerateAccNo_Click(object sender, EventArgs e) { string qry = "SELECT Id,CuType,CuNo,CuOldCuNo FROM A2ZCUNION "; DataTable dt = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry, "A2ZCSMCUS"); int totrec = dt.Rows.Count; if (dt.Rows.Count > 0) { lblProcessing.Text = "Last Process"; foreach (DataRow dr in dt.Rows) { var CType = dr["CuType"].ToString(); var CNo = dr["CuNo"].ToString(); var CuOldCuNo = dr["CuOldCuNo"].ToString(); int code = Converter.GetInteger(CuOldCuNo); string qry1 = "SELECT Id,AccType,CuType,CuNo,OldCuNo FROM A2ZACCOUNT WHERE CuNo='" + CNo + "'"; DataTable dt1 = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry1, "A2ZCSMCUS"); if (dt1.Rows.Count > 0) { foreach (DataRow dr1 in dt1.Rows) { var ParentId = dr1["Id"].ToString(); var AccType = dr1["AccType"].ToString(); A2ZACCOUNTDTO objDTO = new A2ZACCOUNTDTO(); objDTO.Id = Converter.GetSmallInteger(ParentId); objDTO.CuType = Converter.GetSmallInteger(CType); objDTO.CuNo = Converter.GetInteger(CNo); if (AccType == "11") { objDTO.AccAtyClass = 1; } if (AccType == "12") { objDTO.AccAtyClass = 1; } if (AccType == "13") { objDTO.AccAtyClass = 1; } if (AccType == "18") { objDTO.AccAtyClass = 1; } if (AccType == "19") { objDTO.AccAtyClass = 1; } if (AccType == "20") { objDTO.AccAtyClass = 1; } if (AccType == "21") { objDTO.AccAtyClass = 1; } if (AccType == "23") { objDTO.AccAtyClass = 1; } if (AccType == "24") { objDTO.AccAtyClass = 1; } if (AccType == "14") { objDTO.AccAtyClass = 4; } if (AccType == "15") { objDTO.AccAtyClass = 2; } if (AccType == "16") { objDTO.AccAtyClass = 2; } if (AccType == "17") { objDTO.AccAtyClass = 3; } if (AccType == "52") { objDTO.AccAtyClass = 5; } if (AccType == "51") { objDTO.AccAtyClass = 6; } if (AccType == "53") { objDTO.AccAtyClass = 6; } if (AccType == "54") { objDTO.AccAtyClass = 6; } if (AccType == "61") { objDTO.AccAtyClass = 6; } int row2 = A2ZACCOUNTDTO.Update1(objDTO); } } } } GenerateAccNo(); Successful(); }
protected void BtnApprove_Click(object sender, EventArgs e) { try { A2ZRECCTRLDTO getDTO = (A2ZRECCTRLDTO.GetLastRecords(1)); lblNewSRL.Text = Converter.GetString(getDTO.CtrlRecLastNo); A2ZCUNIONDTO MemDTO = new A2ZCUNIONDTO(); A2ZMEMBERDTO Mem1DTO = new A2ZMEMBERDTO(); A2ZACCOUNTDTO Mem2DTO = new A2ZACCOUNTDTO(); Button b = (Button)sender; GridViewRow r = (GridViewRow)b.NamingContainer; Label CTyNo = (Label)gvCUInfo.Rows[r.RowIndex].Cells[5].FindControl("lblcutype"); Label CrNo = (Label)gvCUInfo.Rows[r.RowIndex].Cells[6].FindControl("lblcno"); int a = Converter.GetSmallInteger(CTyNo.Text); int c = Converter.GetSmallInteger(CrNo.Text); Int16 CuType = Converter.GetSmallInteger(a); int CNo = Converter.GetSmallInteger(c); lblCuType.Text = Converter.GetString(CuType); lblCuNo.Text = Converter.GetString(CNo); A2ZCUAPPLICATIONDTO objDTO = (A2ZCUAPPLICATIONDTO.GetInformation(CuType, CNo)); if (objDTO.CreditUnionNo > 0) { objDTO.CuType = CuType; objDTO.CreditUnionNo = CNo; MemDTO.CuType = Converter.GetSmallInteger(objDTO.CuType); MemDTO.CuTypeName = Converter.GetString(objDTO.CuTypeName); MemDTO.CreditUnionNo = Converter.GetInteger(lblNewSRL.Text); MemDTO.CreditUnionName = Converter.GetString(objDTO.CreditUnionName); MemDTO.opendate = Converter.GetDateTime(objDTO.opendate); MemDTO.MemberFlag = Converter.GetSmallInteger(objDTO.MemberFlag); MemDTO.CertificateNo = Converter.GetInteger(objDTO.CertificateNo); MemDTO.AddressL1 = Converter.GetString(objDTO.AddressL1); MemDTO.AddressL2 = Converter.GetString(objDTO.AddressL2); MemDTO.AddressL3 = Converter.GetString(objDTO.AddressL3); MemDTO.TelephoneNo = Converter.GetString(objDTO.TelephoneNo); MemDTO.MobileNo = Converter.GetString(objDTO.MobileNo); MemDTO.Fax = Converter.GetString(objDTO.Fax); MemDTO.email = Converter.GetString(objDTO.email); MemDTO.Division = Converter.GetInteger(objDTO.Division); MemDTO.District = Converter.GetInteger(objDTO.District); MemDTO.Upzila = Converter.GetInteger(objDTO.Upzila); MemDTO.Thana = Converter.GetInteger(objDTO.Thana); MemDTO.GLCashCode = Converter.GetInteger(objDTO.GLCashCode); MemDTO.CuStatusDate = Converter.GetDateTime(objDTO.CuStatusDate); MemDTO.ValueDate = Converter.GetDateTime(objDTO.ValueDate); MemDTO.CreateDate = Converter.GetDateTime(objDTO.CreateDate); objDTO.CuProcFlag = Converter.GetSmallInteger(13); objDTO.CuProcDesc = "Approved"; objDTO.ApprovBy = Converter.GetSmallInteger(SessionStore.GetValue(Params.SYS_USER_ID)); A2ZCSPARAMETERDTO dto = A2ZCSPARAMETERDTO.GetParameterValue(); objDTO.ApprovByDate = Converter.GetDateTime(dto.ProcessDate); MemDTO.CuProcFlag = Converter.GetSmallInteger(objDTO.CuProcFlag); MemDTO.ApprovBy = Converter.GetSmallInteger(objDTO.ApprovBy); MemDTO.ApprovByDate = Converter.GetDateTime(objDTO.ApprovByDate); MemDTO.InputBy = Converter.GetSmallInteger(objDTO.InputBy); MemDTO.VerifyBy = Converter.GetSmallInteger(objDTO.VerifyBy); MemDTO.InputByDate = Converter.GetDateTime(objDTO.InputByDate); MemDTO.VerifyByDate = Converter.GetDateTime(objDTO.VerifyByDate); objDTO.VerifyBy = Converter.GetSmallInteger(MemDTO.VerifyBy); objDTO.VerifyByDate = Converter.GetDateTime(MemDTO.VerifyByDate); Mem1DTO.CuType = Converter.GetSmallInteger(MemDTO.CuType); Mem1DTO.CreditUnionNo = Converter.GetInteger(MemDTO.CreditUnionNo); Mem1DTO.MemberName = Converter.GetString(MemDTO.CreditUnionName); Mem1DTO.OpenDate = Converter.GetDateTime(MemDTO.opendate); Mem1DTO.MemType = 1; Mem2DTO.CuType = Converter.GetSmallInteger(MemDTO.CuType); Mem2DTO.CuNo = Converter.GetInteger(MemDTO.CreditUnionNo); Mem2DTO.AccType = 99; Mem2DTO.AccNo = 0; Mem2DTO.MemberNo = 0; Mem2DTO.Opendate = Converter.GetDateTime(MemDTO.opendate); Mem2DTO.AccStatus = 1; Mem2DTO.AccAtyClass = 6; int roweffect = A2ZCUAPPLICATIONDTO.UpdateInformation2(objDTO); if (roweffect > 0) { int row = A2ZCUNIONDTO.InsertInformation(MemDTO); int row1 = A2ZMEMBERDTO.Insert(Mem1DTO); InsertMiscRecord(); //int row2 = A2ZACCOUNTDTO.Insert(Mem2DTO); DisplayMessage(); gvVerify(); string CheckQuery = "SELECT CuType,CuTypeName,CuNo,CuName,CuOpDt,CuProcDesc FROM A2ZCUAPPLICATION Where CuProcFlag = '12' OR CuProcFlag = '22' and CuStatus !='99'"; DataTable dt = new DataTable(); dt = CommonManager.Instance.GetDataTableByQuery(CheckQuery, "A2ZCSMCUS"); if (dt.Rows.Count <= 0) { DivGridViewCancle.Visible = false; lblmsg1.Visible = true; lblmsg2.Visible = true; } } } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.BtnApprove_Click Problem');</script>"); //throw ex; } }
protected void GetInfo() { try { MSGFlag.Text = "0"; Int64 AccNumber = Converter.GetLong(ItxtAccNo.Text); A2ZACCOUNTDTO getDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (getDTO.a > 0) { if (getDTO.AccStatus == 99) { ItxtAccNo.Text = string.Empty; ItxtAccNo.Focus(); MSGFlag.Text = "1"; AccClosedMSG(); return; } else { lblExLoanBal.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccBalance)); decimal balance = Converter.GetDecimal(lblExLoanBal.Text); ////if (balance < 0) ////{ //// ItxtAccNo.Text = string.Empty; //// ItxtAccNo.Focus(); //// MSGFlag.Text = "1"; //// ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Loan Balance Not Zero');", true); //// return; ////} IlblExSancAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.LoanAmount)); lblExDisbAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.AccDisbAmt)); IlblExNoInstl.Text = Converter.GetString(getDTO.NoInstallment); ItxtNewNoInstal.Text = Converter.GetString(getDTO.NoInstallment); lblExistInstlAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.MonthlyInstallment)); lblExistLastInstlAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.LastInstallment)); IlblExIntRate.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.InterestRate)); ItxtNewInterestRate.Text = Converter.GetString(String.Format("{0:0,0.00}", getDTO.InterestRate)); ItxtIncreaseSanctionAmount.Focus(); } } else { ItxtAccNo.Text = string.Empty; ItxtAccNo.Focus(); MSGFlag.Text = "1"; AccountNotExistsMSG(); return; } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetInfo Problem');</script>"); } }
protected void ddlAccNo_SelectedIndexChanged(object sender, EventArgs e) { txtAccNo.Text = Converter.GetString(ddlAccNo.SelectedValue); Int64 AccNumber = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a > 0) { lblTypeCls.Text = Converter.GetString(accgetDTO.AccAtyClass); lblChkCuType.Text = Converter.GetString(accgetDTO.CuType); lblChkCuNo.Text = Converter.GetString(accgetDTO.CuNo); lblChkMemNo.Text = Converter.GetString(accgetDTO.MemberNo); if (lblTypeCls.Text != "5" && lblTypeCls.Text != "6") { txtAccNo.Text = string.Empty; txtAccNo.Focus(); ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Invalid Account No.');", true); return; } if (txtCreditUNo.Text != string.Empty && (lblCuType.Text != lblChkCuType.Text || lblCuNo.Text != lblChkCuNo.Text)) { txtAccNo.Text = string.Empty; txtAccNo.Focus(); ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Invalid Account No.');", true); return; } if (ChkAllMemNo.Checked == false && txtMemNo.Text != lblChkMemNo.Text) { txtAccNo.Text = string.Empty; txtAccNo.Focus(); ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Invalid Account No.');", true); return; } if (txtCreditUNo.Text == string.Empty) { lblCuType.Text = Converter.GetString(accgetDTO.CuType); lblCuNo.Text = Converter.GetString(accgetDTO.CuNo); txtCreditUNo.Text = lblCuType.Text + "-" + lblCuNo.Text; ddlCreditUNo.SelectedValue = Converter.GetString(lblCuType.Text + lblCuNo.Text); Int16 CuType = Converter.GetSmallInteger(lblCuType.Text); int CNo = Converter.GetSmallInteger(lblCuNo.Text); string sqquery = @"SELECT MemNo,MemName FROM A2ZMEMBER WHERE CuNo='" + CNo + "'and CuType='" + CuType + "' GROUP BY MemNo,MemName"; ddlMemNo = DataAccessLayer.BLL.CommonManager.Instance.FillDropDownListWithSelect(sqquery, ddlMemNo, "A2ZCSMCUS"); txtMemNo.Text = Converter.GetString(accgetDTO.MemberNo); ddlMemNo.SelectedValue = Converter.GetString(txtMemNo.Text); txtAccType.Text = Converter.GetString(accgetDTO.AccType); ddlAccType.SelectedValue = Converter.GetString(accgetDTO.AccType); ChkAllMemNo.Checked = false; ChkAllAccType.Checked = false; } } }
public void GetAccInfo() { try { Int64 AccNumber = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a == 0) { InvalidAccMSG(); txtAccNo.Text = string.Empty; txtAccNo.Focus(); return; } else { lblAccBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.AccBalance)); lblBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.AccBalance)); lblBalLienAmount.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.AccLienAmt)); lblStatP.Text = Converter.GetString(accgetDTO.AccStatus); DateTime dt = Converter.GetDateTime(accgetDTO.AccStatusDate); string date = dt.ToString("dd/MM/yyyy"); lblCurrRef.Text = Converter.GetString(accgetDTO.AccStatusNote); if (lblStatP.Text == "98") { txtAccNo.Text = string.Empty; txtAccNo.Focus(); InvalidAccStatusChg(); return; } if (lblStatP.Text == "50") { lblBalLien.Visible = true; lblBalLienAmount.Visible = true; } if (date == "01/01/0001") { lblCurrStatDt.Text = string.Empty; } else { lblCurrStatDt.Text = date; } string qry1 = "SELECT AccStatusDescription FROM A2ZACCSTATUS where AccStatusCode='" + lblStatP.Text + "'"; DataTable dt1 = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry1, "A2ZCSMCUS"); if (dt1.Rows.Count > 0) { lblCurrStatus.Text = Converter.GetString(dt1.Rows[0]["AccStatusDescription"]); } lblCuType.Text = Converter.GetString(accgetDTO.CuType); lblCuNo.Text = Converter.GetString(accgetDTO.CuNo); txtCreditUNo.Text = (lblCuType.Text + "-" + lblCuNo.Text); txtMemNo.Text = Converter.GetString(accgetDTO.MemberNo); CtrlAccType.Text = Converter.GetString(accgetDTO.AccType); lblcls.Text = Converter.GetString(accgetDTO.AccAtyClass); Int16 AccType = Converter.GetSmallInteger(CtrlAccType.Text); A2ZACCTYPEDTO get3DTO = (A2ZACCTYPEDTO.GetInformation(AccType)); if (get3DTO.AccTypeCode > 0) { lblAccTitle.Text = Converter.GetString(get3DTO.AccTypeDescription); } Int16 CType = Converter.GetSmallInteger(lblCuType.Text); int CNo = Converter.GetInteger(lblCuNo.Text); A2ZCUNIONDTO get5DTO = (A2ZCUNIONDTO.GetInformation(CType, CNo)); if (get5DTO.NoRecord > 0) { lblCuName.Text = Converter.GetString(get5DTO.CreditUnionName); } Int16 CUType = Converter.GetSmallInteger(lblCuType.Text); int CUNo = Converter.GetInteger(lblCuNo.Text); int MNo = Converter.GetInteger(txtMemNo.Text); A2ZMEMBERDTO get6DTO = (A2ZMEMBERDTO.GetInformation(CUType, CUNo, MNo)); if (get6DTO.NoRecord > 0) { lblMemName.Text = Converter.GetString(get6DTO.MemberName); } } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetAccInfo Problem');</script>"); //throw ex; } }
public void GetAccInfo() { try { Int64 AccNumber = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a == 0) { InvalidAccountNoMSG(); txtAccNo.Text = string.Empty; txtAccNo.Focus(); return; } else { CtrlAccStatus.Text = Converter.GetString(accgetDTO.AccStatus); if (CtrlAccStatus.Text == "98") { txtAccNo.Text = string.Empty; txtAccNo.Focus(); AccTransferedMSG(); return; } Int16 AccStat = Converter.GetSmallInteger(CtrlAccStatus.Text); A2ZACCSTATUSDTO get0DTO = (A2ZACCSTATUSDTO.GetInformation(AccStat)); if (get0DTO.AccStatusCode > 0) { txtstat.Text = Converter.GetString(get0DTO.AccStatusDescription); } lblCuType.Text = Converter.GetString(accgetDTO.CuType); lblCuNo.Text = Converter.GetString(accgetDTO.CuNo); txtCreditUNo.Text = (lblCuType.Text + "-" + lblCuNo.Text); txtCULBMemNo.Text = Converter.GetString(accgetDTO.MemberNo); CtrlAccType.Text = Converter.GetString(accgetDTO.AccType); lblcls.Text = Converter.GetString(accgetDTO.AccAtyClass); if (lblcls.Text == "7") { string input2 = txtAccNo.Text; string paytype = input2.Substring(12, 4); int atyclass = Converter.GetInteger(lblcls.Text); int paycode = Converter.GetInteger(paytype); A2ZPAYTYPEDTO get1DTO = (A2ZPAYTYPEDTO.GetInformation(atyclass, paycode)); if (get1DTO.PayTypeCode > 0) { lblAccTitle.Text = Converter.GetString(get1DTO.PayTypeDescription); int pcode = Converter.GetInteger(paytype); A2ZTRNCODEDTO get2DTO = (A2ZTRNCODEDTO.GetInformation99(pcode)); if (get2DTO.TrnCode > 0) { lblTrnCode.Text = Converter.GetString(get2DTO.TrnCode); } } } else { Int16 AccType = Converter.GetSmallInteger(CtrlAccType.Text); A2ZACCTYPEDTO get3DTO = (A2ZACCTYPEDTO.GetInformation(AccType)); if (get3DTO.AccTypeCode > 0) { lblAccTitle.Text = Converter.GetString(get3DTO.AccTypeDescription); } int AType = Converter.GetInteger(CtrlAccType.Text); A2ZTRNCODEDTO get4DTO = (A2ZTRNCODEDTO.GetInformation01(AType)); if (get4DTO.TrnCode > 0) { lblTrnCode.Text = Converter.GetString(get4DTO.TrnCode); } } Int16 CType = Converter.GetSmallInteger(lblCuType.Text); int CNo = Converter.GetInteger(lblCuNo.Text); A2ZCUNIONDTO get5DTO = (A2ZCUNIONDTO.GetInformation(CType, CNo)); if (get5DTO.NoRecord > 0) { hdnCashCode.Text = Converter.GetString(get5DTO.GLCashCode); if (lblModule.Text == "06" && hdnCashCode.Text != lblCashCode.Text) { txtAccNo.Text = string.Empty; txtCreditUNo.Text = string.Empty; txtCULBMemNo.Text = string.Empty; txtAccNo.Focus(); AccessDeniedMSG(); return; } lblCuName.Text = Converter.GetString(get5DTO.CreditUnionName); } Int16 CUType = Converter.GetSmallInteger(lblCuType.Text); int CUNo = Converter.GetInteger(lblCuNo.Text); int MNo = Converter.GetInteger(txtCULBMemNo.Text); A2ZMEMBERDTO get6DTO = (A2ZMEMBERDTO.GetInformation(CUType, CUNo, MNo)); if (get6DTO.NoRecord > 0) { lblMemName.Text = Converter.GetString(get6DTO.MemberName); } if (lblcls.Text == "4") { DateTime dt0 = Converter.GetDateTime(accgetDTO.LastTrnDate); string date0 = dt0.ToString("dd/MM/yyyy"); tLastTrnDate.Text = date0; if (tLastTrnDate.Text == "01/01/0001") { tLastTrnDate.Text = string.Empty; } DateTime dt12 = Converter.GetDateTime(accgetDTO.MatruityDate); string date12 = dt12.ToString("dd/MM/yyyy"); tMaturityDt.Text = date12; if (tMaturityDt.Text == "01/01/0001") { tMaturityDt.Text = string.Empty; } tAccPeriod.Text = Converter.GetString(accgetDTO.Period); tTotalDeposit.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.TotDepositAmount)); tMthDeposit.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.DepositAmount)); DateTime TrnDate = DateTime.ParseExact(lblProcDate.Text, "dd/MM/yyyy", System.Globalization.CultureInfo.InvariantCulture); Int16 CuType = Converter.GetSmallInteger(lblCuType.Text); int CuNo = Converter.GetInteger(lblCuNo.Text); Int16 Acctype = Converter.GetSmallInteger(CtrlAccType.Text); Int64 AccNo = Converter.GetLong(txtAccNo.Text); int MemNumber = Converter.GetInteger(txtCULBMemNo.Text); A2ZPENSIONDEFAULTERDTO getDTO = (A2ZPENSIONDEFAULTERDTO.GetPensionDepInformation(TrnDate, CuType, CuNo, MemNumber, Acctype, AccNumber)); if (getDTO.CuType > 0) { tDueDepositAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", (getDTO.DueDepositAmt))); tUptoDate.Text = Converter.GetString(getDTO.UptoDate); } } } string qry = "SELECT Id,AccNo,AccOpenDate,AccMatureDate,AccRenwlDate,AccPeriod,AccBalance,AccOrgAmt,AccPrincipal,AccIntRate,AccLoanSancAmt,AccLoanSancDate,AccDisbAmt,AccDisbDate,AccNoInstl,AccLoanInstlAmt,AccLoanLastInstlAmt,AccAtyClass,AccOldNumber,AccCertNo,AccFixedMthInt FROM A2ZACCOUNT where AccType ='" + CtrlAccType.Text + "' and CuType='" + lblCuType.Text + "' and CuNo='" + lblCuNo.Text + "' and MemNo='" + txtCULBMemNo.Text + "' and AccNo ='" + txtAccNo.Text + "'"; DataTable dt = DataAccessLayer.BLL.CommonManager.Instance.GetDataTableByQuery(qry, "A2ZCSMCUS"); if (dt.Rows.Count > 0) { //For Report Header Parameter class wise // Loan Information tAccBalance.Text = Converter.GetString(dt.Rows[0]["AccBalance"]); tAccLoanSancAmt.Text = Converter.GetString(dt.Rows[0]["AccLoanSancAmt"]); tAccLoanSancDate.Text = Converter.GetString(dt.Rows[0]["AccLoanSancDate"]); tAccDisbAmt.Text = Converter.GetString(dt.Rows[0]["AccDisbAmt"]); tAccDisbDate.Text = Converter.GetString(dt.Rows[0]["AccDisbDate"]); tAccNoInstl.Text = Converter.GetString(dt.Rows[0]["AccNoInstl"]); tAccLoanInstlAmt.Text = Converter.GetString(dt.Rows[0]["AccLoanInstlAmt"]); tAccLoanLastInstlAmt.Text = Converter.GetString(dt.Rows[0]["AccLoanLastInstlAmt"]); tOpenDt.Text = Converter.GetString(dt.Rows[0]["AccOpenDate"]); tClass.Text = Converter.GetString(dt.Rows[0]["AccAtyClass"]); // FOR A/C TYPE Class int AccTypeClass = Converter.GetSmallInteger(tClass.Text); if (AccTypeClass == 2 || AccTypeClass == 3) { // tOpenDt.Text = Converter.GetString(dt.Rows[0]["AccOpenDate"]); tMaturityDt.Text = Converter.GetString(dt.Rows[0]["AccMatureDate"]); tRenewalDt.Text = Converter.GetString(dt.Rows[0]["AccRenwlDate"]); tAccPeriod.Text = Converter.GetString(dt.Rows[0]["AccPeriod"]); tOrgAmt.Text = Converter.GetString(dt.Rows[0]["AccOrgAmt"]); tPrincipleAmt.Text = Converter.GetString(dt.Rows[0]["AccPrincipal"]); tOldAccount.Text = Converter.GetString(dt.Rows[0]["AccOldNumber"]); tAccCertNo.Text = Converter.GetString(dt.Rows[0]["AccCertNo"]); } if (AccTypeClass == 2) { // Int Rate tIntRate.Text = Converter.GetString(dt.Rows[0]["AccIntRate"]); } if (AccTypeClass == 3) { // Monthly Benefit tAccFixedMthInt.Text = Converter.GetString(dt.Rows[0]["AccFixedMthInt"]); } // decimal b = Converter.GetDecimal(dt.Rows[0]["AccBalance"]); } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetAccInfo Problem');</script>"); //throw ex; } }
public void GetAccInfo1() { try { Int64 AccNumber = Converter.GetLong(txtAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a == 0) { InvalidAccount(); txtAccNo.Text = string.Empty; txtAccNo.Focus(); return; } else { CtrlAccStatus.Text = Converter.GetString(accgetDTO.AccStatus); if (CtrlAccStatus.Text == "98") { txtAccNo.Text = string.Empty; txtAccNo.Focus(); TransferedAccount(); return; } if (CtrlAccStatus.Text == "99") { txtAccNo.Text = string.Empty; txtAccNo.Focus(); ClosedAccount(); return; } CtrlLadgerBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.AccBalance)); CtrlLienAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.AccLienAmt)); CtrlLoanSancAmt.Text = Converter.GetString(String.Format("{0:0,0.00}", accgetDTO.LoanAmount)); CtrlAccType.Text = Converter.GetString(accgetDTO.AccType); lblcls.Text = Converter.GetString(accgetDTO.AccAtyClass); UnPostValue(); lblCuType.Text = Converter.GetString(accgetDTO.CuType); lblCuNo.Text = Converter.GetString(accgetDTO.CuNo); txtCreditUNo.Text = (lblCuType.Text + "-" + lblCuNo.Text); txtMemNo.Text = Converter.GetString(accgetDTO.MemberNo); lblAtyClass.Text = Converter.GetString(accgetDTO.AccAtyClass); if (lblAtyClass.Text == "7") { string input = txtAccNo.Text; lblPayType.Text = input.Substring(13, 3); int paytype = Converter.GetInteger(lblPayType.Text); A2ZTRNCODEDTO get3DTO = (A2ZTRNCODEDTO.GetInformation99(paytype)); if (get3DTO.TrnCode > 0) { lblTrnCode.Text = Converter.GetString(get3DTO.TrnCode); lblAccTitle.Text = Converter.GetString(get3DTO.TrnDescription); } } else { lblPayType.Text = "0"; Int16 AccType = Converter.GetSmallInteger(CtrlAccType.Text); A2ZACCTYPEDTO get3DTO = (A2ZACCTYPEDTO.GetInformation(AccType)); if (get3DTO.AccTypeCode > 0) { lblAccTitle.Text = Converter.GetString(get3DTO.AccTypeDescription); } int AType = Converter.GetInteger(CtrlAccType.Text); A2ZTRNCODEDTO get4DTO = (A2ZTRNCODEDTO.GetInformation01(AType)); if (get4DTO.TrnCode > 0) { lblTrnCode.Text = Converter.GetString(get4DTO.TrnCode); } } Int16 CType = Converter.GetSmallInteger(lblCuType.Text); int CNo = Converter.GetInteger(lblCuNo.Text); A2ZCUNIONDTO get5DTO = (A2ZCUNIONDTO.GetInformation(CType, CNo)); if (get5DTO.NoRecord > 0) { lblCuName.Text = Converter.GetString(get5DTO.CreditUnionName); } Int16 CUType = Converter.GetSmallInteger(lblCuType.Text); int CUNo = Converter.GetInteger(lblCuNo.Text); int MNo = Converter.GetInteger(txtMemNo.Text); A2ZMEMBERDTO get6DTO = (A2ZMEMBERDTO.GetInformation(CUType, CUNo, MNo)); if (get6DTO.NoRecord > 0) { lblMemName.Text = Converter.GetString(get6DTO.MemberName); } } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetAccInfo Problem');</script>"); //throw ex; } }
public void GetAccInfo2() { try { Int64 AccNumber = Converter.GetLong(txtTrnAccNo.Text); A2ZACCOUNTDTO accgetDTO = (A2ZACCOUNTDTO.GetInfoAccNo(AccNumber)); if (accgetDTO.a == 0) { InvalidAccount(); txtTrnAccNo.Text = string.Empty; txtTrnAccNo.Focus(); return; } else { CtrlAccStatus.Text = Converter.GetString(accgetDTO.AccStatus); if (CtrlAccStatus.Text == "98") { txtTrnAccNo.Text = string.Empty; txtTrnAccNo.Focus(); TransferedAccount(); return; } if (CtrlAccStatus.Text == "99") { txtTrnAccNo.Text = string.Empty; txtTrnAccNo.Focus(); ClosedAccount(); return; } txtTrnStaffCode.Text = Converter.GetString(accgetDTO.MemberNo); CtrlTrnAccType.Text = Converter.GetString(accgetDTO.AccType); lblcls.Text = Converter.GetString(accgetDTO.AccAtyClass); lblTrnAtyClass.Text = Converter.GetString(accgetDTO.AccAtyClass); if (lblTrnAtyClass.Text == "5" || lblTrnAtyClass.Text == "6") { lblIntAmt.Visible = true; txtIntAmt.Visible = true; lblPrincAmt.Visible = true; txtPrincAmt.Visible = true; txtTrnAmount.ReadOnly = true; } if (lblAtyClass.Text == "7") { string input = txtTrnAccNo.Text; lblTrnPayType.Text = input.Substring(13, 3); int paytype = Converter.GetInteger(lblTrnPayType.Text); A2ZTRNCODEDTO get3DTO = (A2ZTRNCODEDTO.GetInformation99(paytype)); if (get3DTO.TrnCode > 0) { lblTrnAccTitle.Text = Converter.GetString(get3DTO.TrnDescription); } } else { lblTrnPayType.Text = "0"; Int16 AccType = Converter.GetSmallInteger(CtrlTrnAccType.Text); A2ZACCTYPEDTO get3DTO = (A2ZACCTYPEDTO.GetInformation(AccType)); if (get3DTO.AccTypeCode > 0) { lblTrnAccTitle.Text = Converter.GetString(get3DTO.AccTypeDescription); } } int MNo = Converter.GetInteger(txtTrnStaffCode.Text); A2ZMEMBERDTO get6DTO = (A2ZMEMBERDTO.GetInformation(0, 0, MNo)); if (get6DTO.NoRecord > 0) { lblTrnStaffName.Text = Converter.GetString(get6DTO.MemberName); } } } catch (Exception ex) { Page.ClientScript.RegisterStartupScript(this.GetType(), "scriptkey", "<script>alert('System Error.GetAccInfo Problem');</script>"); //throw ex; } }
protected void btnSave_Click(object sender, EventArgs e) { if (txtDescription.Text == string.Empty) { txtDescription.Focus(); ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Please Input Description');", true); return; } if (txtAmount.Text == string.Empty) { txtAmount.Focus(); ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Please Input Amount');", true); return; } if (ddlCash.SelectedIndex == 0) { ScriptManager.RegisterStartupScript(this, GetType(), "showalert", "alert('Please Select By Cash Code');", true); return; } try { A2ZVCHNOCTRLDTO getDTO = new A2ZVCHNOCTRLDTO(); getDTO = (A2ZVCHNOCTRLDTO.GetLastDefaultVchNo()); if (rbtOptReceive.Checked == true) { CtrlVoucherNo.Text = "CBR" + getDTO.RecLastNo.ToString("000000"); } else if (rbtOptPayment.Checked == true) { CtrlVoucherNo.Text = "CBP" + getDTO.RecLastNo.ToString("000000"); } else { CtrlVoucherNo.Text = "CBJ" + getDTO.RecLastNo.ToString("000000"); } var prm = new object[14]; prm[0] = lblID.Text; prm[1] = CtrlVoucherNo.Text; prm[2] = Converter.GetDateToYYYYMMDD(lblProcDate.Text); prm[3] = "50"; prm[4] = "Cash Box"; prm[5] = txtPartyCode.Text; prm[6] = CtrlAccType.Text; prm[7] = txtAccNo.Text; prm[8] = ddlCurrency.SelectedValue; prm[9] = "1"; prm[10] = lblTrnMode.Text; prm[11] = ddlCash.SelectedValue; prm[12] = txtAmount.Text; prm[13] = txtDescription.Text; int result = Converter.GetInteger(CommonManager.Instance.GetScalarValueBySp("Sp_UpdateCashBoxTransaction", prm, "A2ZACGMS")); if (result == 0) { UpdatedMSG(); ClearInformation(); Int64 keyno = Converter.GetLong(ddlCash.SelectedValue); A2ZACCOUNTDTO get1DTO = (A2ZACCOUNTDTO.GetInfoAccNo(keyno)); if (get1DTO.AccNo > 0) { txtCashBalance.Text = Converter.GetString(String.Format("{0:0,0.00}", get1DTO.AccBalance)) + " " + txtLedgerCurrency.Text; } txtPartyCode.Focus(); } } catch (Exception ex) { throw ex; } }