Beispiel #1
0
        private void lkpEdtPaymentGroup_EditValueChanged(object sender, System.EventArgs e)
        {
            if (lkpEdtPayment.EditValue != null &&
                myPaymentCodeLookupBuilder != null &&
                lkpEdtPaymentGroup.EditValue != null &&
                myPaymentGroupCodeLookupBuilder != null &&
                lkpEdtPaymentGroup.EditValue.ToString() != "")
            {
                myPaymentCodeLookupBuilder.Refresh(lkpEdtPaymentGroup.EditValue.ToString());
                if (((DataTable)lkpEdtPayment.Properties.DataSource).Rows.Count == 1)
                {
                    lkpEdtPayment.ItemIndex = 0;
                    lkpEdtPayment.Properties.ForceInitialize();
                }

                lkpEdtIPP.Visible  = lkpEdtPaymentGroup.EditValue.ToString() == ACMSPOS2.PaymentGroupCode.IPP;
                lkpEdtIPP.Enabled  = lkpEdtIPP.Visible;
                label4.Visible     = lkpEdtIPP.Visible;
                myPaymentGroupCode = lkpEdtPaymentGroup.Text;
            }

            if (myIPPLookupEditBuilder != null && lkpEdtIPP.Text.Length > 0)
            {
                string cmdText = "Select A.strIPP From tblBank A Inner Join tblIPP B on A.strBankCode = B.strBankCode " +
                                 " Where B.nIPPID = @nIPPID ";

                int            ippID  = ACMS.Convert.ToInt32(lkpEdtIPP.Text);
                ACMSDAL.TblIPP sqlIPP = new ACMSDAL.TblIPP();
                DataTable      table  = sqlIPP.LoadData(cmdText, new string[] { "@nIPPID" }, new object[] { ippID });
                if (table.Rows.Count > 0)
                {
                    lkpEdtPayment.EditValue = table.Rows[0]["strIPP"];
                }
            }
        }
Beispiel #2
0
        private void lkpEdtIPP_EditValueChanged(object sender, System.EventArgs e)
        {
            if (myIPPLookupEditBuilder != null && lkpEdtIPP.Text.Length > 0)
            {
                string cmdText = "Select A.strIPP From tblBank A Inner Join tblIPP B on A.strBankCode = B.strBankCode " +
                                 " Where B.nIPPID = @nIPPID ";

                int            ippID  = ACMS.Convert.ToInt32(lkpEdtIPP.EditValue);
                ACMSDAL.TblIPP sqlIPP = new ACMSDAL.TblIPP();
                DataTable      table  = sqlIPP.LoadData(cmdText, new string[] { "@nIPPID" }, new object[] { ippID });
                if (table.Rows.Count > 0)
                {
                    lkpEdtPayment.EditValue = table.Rows[0]["strIPP"];
                }
            }
        }
Beispiel #3
0
        private void lkpEdtPaymentGroup_EditValueChanged(object sender, System.EventArgs e)
        {
            if (lkpEdtPayment.EditValue != null &&
                myPaymentCodeLookupBuilder != null &&
                lkpEdtPaymentGroup.EditValue != null &&
                myPaymentGroupCodeLookupBuilder != null &&
                lkpEdtPaymentGroup.EditValue.ToString() != "")
            {
                myPaymentCodeLookupBuilder.Refresh(lkpEdtPaymentGroup.EditValue.ToString());
                if (((DataTable)lkpEdtPayment.Properties.DataSource).Rows.Count == 1)
                {
                    lkpEdtPayment.ItemIndex = 0;
                    lkpEdtPayment.Properties.ForceInitialize();
                }

                lkpEdtIPP.Visible = lkpEdtPaymentGroup.EditValue.ToString() == ACMSPOS2.PaymentGroupCode.IPP;
                lkpEdtIPP.Enabled = lkpEdtIPP.Visible;
                label4.Visible = lkpEdtIPP.Visible;
                myPaymentGroupCode = lkpEdtPaymentGroup.Text;
            }

            if (myIPPLookupEditBuilder != null && lkpEdtIPP.Text.Length > 0)
            {
                string cmdText = "Select A.strIPP From tblBank A Inner Join tblIPP B on A.strBankCode = B.strBankCode " +
                    " Where B.nIPPID = @nIPPID ";

                int ippID = ACMS.Convert.ToInt32(lkpEdtIPP.Text);
                ACMSDAL.TblIPP sqlIPP = new ACMSDAL.TblIPP();
                DataTable table = sqlIPP.LoadData(cmdText, new string[]{"@nIPPID"}, new object[]{ippID});
                if (table.Rows.Count > 0)
                {
                    lkpEdtPayment.EditValue = table.Rows[0]["strIPP"];
                }
            }
        }
Beispiel #4
0
        private void lkpEdtIPP_EditValueChanged(object sender, System.EventArgs e)
        {
            if (myIPPLookupEditBuilder != null && lkpEdtIPP.Text.Length > 0)
            {
                string cmdText = "Select A.strIPP From tblBank A Inner Join tblIPP B on A.strBankCode = B.strBankCode " +
                                " Where B.nIPPID = @nIPPID ";

                int ippID = ACMS.Convert.ToInt32(lkpEdtIPP.EditValue);
                ACMSDAL.TblIPP sqlIPP = new ACMSDAL.TblIPP();
                DataTable table = sqlIPP.LoadData(cmdText, new string[]{"@nIPPID"}, new object[]{ippID});
                if (table.Rows.Count > 0)
                {
                    lkpEdtPayment.EditValue = table.Rows[0]["strIPP"];
                }
            }
        }