Пример #1
0
        private void btnedit_Click_1(object sender, EventArgs e)
        {
            if (grdDataViewer.CurrentRow != null)
            {
                int    col = 0;
                int    row = grdDataViewer.CurrentRow.Index;
                string val = grdDataViewer[col, row].Value.ToString();

                frmGhabzEdit fge = new frmGhabzEdit();

                fge.txtid.Text = val;
                fge.stdno      = grdDataViewer["stdno", row].Value.ToString();
                fge.idsearch_Click();
                fge.ShowDialog();


                if (btnfilter.Enabled == true)
                {
                    btnfilter.PerformClick();
                }
                else
                {
                    ghabz     pm = new ghabz();
                    DataTable dt = new DataTable();
                    dt = pm.Select();
                    grdDataViewer.DataSource = dt;
                }
            }
        }
Пример #2
0
        private void btnGhabzEdit_Click(object sender, EventArgs e)
        {
            int    col = 0;
            int    row = grdDataViewGhabz.CurrentRow.Index;
            string val = grdDataViewGhabz[col, row].Value.ToString();

            frmGhabzEdit fge = new frmGhabzEdit();

            fge.txtid.Text = val;
            fge.stdno      = grdDataViewGhabz["stdno", row].Value.ToString();
            fge.idsearch_Click();
            fge.ShowDialog();

            fillGhabzInfo();
        }