コード例 #1
0
        private void button1_Click(object sender, EventArgs e)
        {
            ConsultMaestro concep = new ConsultMaestro();

            concep.ShowDialog();

            if (concep.DialogResult == DialogResult.OK)
            {
                Txt_1.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                             Cells[0].Value.ToString();
            }
        }
コード例 #2
0
ファイル: MDIParent1.cs プロジェクト: pauulavas/Prototipo2P
        private void unoToolStripMenuItem2_Click(object sender, EventArgs e)
        {
            Form frmC = Application.OpenForms.Cast <Form>().FirstOrDefault(x => x is ConsultMaestro);

            if (Consult_Uno == false || frmC == null)
            {
                if (frmC == null)
                {
                    consult_uno = new ConsultMaestro();
                }

                consult_uno.MdiParent = this;
                consult_uno.Show();
                Application.DoEvents();
                Consult_Uno = true;
            }
            else
            {
                consult_uno.WindowState = System.Windows.Forms.FormWindowState.Normal;
            }
        }
コード例 #3
0
ファイル: MantMaestro.cs プロジェクト: pauulavas/Prototipo2P
        private void Btn_consultar_Click(object sender, EventArgs e)
        {
            ConsultMaestro concep = new ConsultMaestro();

            concep.ShowDialog();

            if (concep.DialogResult == DialogResult.OK)
            {
                Txt_1.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                             Cells[0].Value.ToString();
                Txt_2.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                             Cells[1].Value.ToString();
                Txt_3.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                             Cells[2].Value.ToString();
                Txt_4.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                             Cells[3].Value.ToString();
                Txt_5.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                             Cells[4].Value.ToString();
                Cbo_estado.Text = concep.Dgv_consulta1.Rows[concep.Dgv_consulta1.CurrentRow.Index].
                                  Cells[5].Value.ToString();
            }
        }