예제 #1
0
        private void btnOk_Click(object sender, EventArgs e)
        {
            FrmEmp em = new FrmEmp();

            //em.fill();
            FMessageBox.Show("d");
            this.Visible = false;
        }
예제 #2
0
        private void pictureBox1_Click(object sender, EventArgs e)
        {
            FrmEmp fe = new FrmEmp();

            fe.ShowDialog();
        }
예제 #3
0
        private void dgvperson_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        {
            if (dgvperson.CurrentRow.Cells[0].Value != null)
            {
                p.ID = Convert.ToInt32(dgvperson.CurrentRow.Cells[0].Value.ToString());
            }
            if (dgvperson.CurrentRow.Cells[1].Value != null)
            {
                p.Name = dgvperson.CurrentRow.Cells[1].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[2].Value != null)
            {
                p.Family = dgvperson.CurrentRow.Cells[2].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[3].Value != null)
            {
                p.BimeNum = dgvperson.CurrentRow.Cells[3].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[4].Value != null)
            {
                p.EmpCode = dgvperson.CurrentRow.Cells[4].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[5].Value != null)
            {
                p.FatherName = dgvperson.CurrentRow.Cells[5].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[6].Value != null)
            {
                p.NationalCode = dgvperson.CurrentRow.Cells[6].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[7].Value != null)
            {
                p.EmpShSh = dgvperson.CurrentRow.Cells[7].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[8].Value != null)
            {
                p.EmpMSh1 = dgvperson.CurrentRow.Cells[8].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[9].Value != null)
            {
                p.EmpMSh2 = dgvperson.CurrentRow.Cells[9].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[10].Value != null)
            {
                p.CitySodor = dgvperson.CurrentRow.Cells[10].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[11].Value != null)
            {
                p.CityCodeSodor = dgvperson.CurrentRow.Cells[11].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[12].Value != null)
            {
                p.BakhshSodor = dgvperson.CurrentRow.Cells[12].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[13].Value != null)
            {
                p.CityTavalod = dgvperson.CurrentRow.Cells[13].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[14].Value != null)
            {
                p.CityTavalodCode = dgvperson.CurrentRow.Cells[14].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[15].Value != null)
            {
                p.CountryTavalod = dgvperson.CurrentRow.Cells[15].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[16].Value != null)
            {
                p.CountryTavalodCode = dgvperson.CurrentRow.Cells[16].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[17].Value != null)
            {
                p.TavalodDate = Convert.ToInt32(dgvperson.CurrentRow.Cells[17].Value.ToString());
            }
            if (dgvperson.CurrentRow.Cells[18].Value != null)
            {
                p.Job = dgvperson.CurrentRow.Cells[18].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[19].Value != null)
            {
                p.JobCode = dgvperson.CurrentRow.Cells[19].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[20].Value != null)
            {
                p.Sex = dgvperson.CurrentRow.Cells[20].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[21].Value != null)
            {
                p.Married = dgvperson.CurrentRow.Cells[21].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[22].Value != null)
            {
                p.Child = dgvperson.CurrentRow.Cells[22].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[23].Value != null)
            {
                p.National = dgvperson.CurrentRow.Cells[23].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[24].Value != null)
            {
                p.Education = dgvperson.CurrentRow.Cells[24].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[25].Value != null)
            {
                p.Branch = dgvperson.CurrentRow.Cells[25].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[26].Value != null)
            {
                p.UniverCity = dgvperson.CurrentRow.Cells[26].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[27].Value != null)
            {
                p.YearEducation = Convert.ToInt32(dgvperson.CurrentRow.Cells[27].Value.ToString());
            }
            if (dgvperson.CurrentRow.Cells[28].Value != null)
            {
                p.Tell = dgvperson.CurrentRow.Cells[28].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[29].Value != null)
            {
                p.CodeTell = dgvperson.CurrentRow.Cells[29].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[30].Value != null)
            {
                p.Mobile = dgvperson.CurrentRow.Cells[30].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[31].Value != null)
            {
                p.Email = dgvperson.CurrentRow.Cells[31].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[32].Value != null)
            {
                p.Address = dgvperson.CurrentRow.Cells[32].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[33].Value != null)
            {
                p.Post = dgvperson.CurrentRow.Cells[33].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[34].Value != null)
            {
                p.JobNum = dgvperson.CurrentRow.Cells[34].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[35].Value != null)
            {
                p.JobDate = Convert.ToInt32(dgvperson.CurrentRow.Cells[35].Value.ToString());
            }
            if (dgvperson.CurrentRow.Cells[36].Value != null)
            {
                p.BankName = dgvperson.CurrentRow.Cells[36].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[37].Value != null)
            {
                p.Banknum = dgvperson.CurrentRow.Cells[37].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[38].Value != null)
            {
                p.BankCard = dgvperson.CurrentRow.Cells[38].Value.ToString();
            }
            if (dgvperson.CurrentRow.Cells[39].Value != null)
            {
                p.Pic = dgvperson.CurrentRow.Cells[39].Value.ToString();
            }

            if (hokm == "feo")
            {
                emp = dgvperson.CurrentRow.Cells[1].Value.ToString() + " " + dgvperson.CurrentRow.Cells[2].Value.ToString();
                this.Close();
            }
            else
            {
                FrmEmp mp = new FrmEmp(p);

                mp.ShowDialog();

                InitializeBinding();
            }
        }
예제 #4
0
        private void metroButton1_Click(object sender, EventArgs e)
        {
            FrmEmp mp = new FrmEmp();

            mp.ShowDialog();
        }