Exemplo n.º 1
0
        private void tsmiPayEdit_Click(object sender, EventArgs e)
        {
            if (dgvAllPay.Rows.Count > 0)
            {
                Int16 PayID = Convert.ToInt16(dgvAllPay.CurrentRow.Cells[0].Value);

                TransactionActivity.TransactionLog TL = new TransactionActivity.TransactionLog();
                DataTable dtDFPP = TL.Select(PayID);///// DFPP= Delete From Person Pay

                if (dtDFPP != null)
                {
                    frmPay fp = new frmPay();

                    if (dtDFPP.Rows[0]["payMethod"].ToString() == "doc")
                    {
                        //frmCheck FC = new frmCheck();
                        //FC.PersonalId = Convert.ToInt16(CurrentPesonalID);
                        //FC.ShowDialog(this);
                        fp.Payis = "cheque";
                    }
                    else if (dtDFPP.Rows[0]["payMethod"].ToString() == "cash")
                    {
                        fp.Payis = "cash";
                    }

                    fp.CurrentPesonalID = Convert.ToDecimal(CurrentPesonalID);
                    fp.mode             = "edit";
                    fp.PayId            = Convert.ToDecimal(dgvAllPay.CurrentRow.Cells[0].Value);
                    fp.Text             = "اصلاح پرداختی";
                    fp.ShowDialog(this);
                }
            }
        }
Exemplo n.º 2
0
        private void ToolStripMenuItemCash_Click(object sender, EventArgs e)
        {
            frmPay fp = new frmPay();

            fp.CurrentPesonalID = Convert.ToDecimal(cSC.ID);
            fp.ShowDialog(this);
        }