Beispiel #1
0
        //private void dgvMzjld_CellDoubleClick(object sender, DataGridViewCellEventArgs e)
        //{
        //    if (dgvMzjld.SelectedRows[0].Cells[0].Value.ToString()!="")
        //    {
        //       string mzid = dgvMzjld.SelectedRows[0].Cells[1].Value.ToString();
        //       String patid = Convert.ToString(dgvMzjld.SelectedRows[0].Cells[0].Value);
        //       mzjldEdit mzjld1 = new mzjldEdit(mzid, patid);
        //       mzjld1.ShowDialog();
        //    }
        //}

        //private void dgvMzjld_CellMouseClick(object sender, DataGridViewCellMouseEventArgs e)
        //{

        //        if (e.Button == MouseButtons.Right)
        //        {
        //            dgvMzjld.ContextMenuStrip = conMenu;
        //            conMenu.Show(dgvMzjld, new Point(e.X, e.Y));
        //        }

        //}


        private void MZZJDToolStripMenuItem_Click(object sender, EventArgs e)
        {
            string  mzID  = dgvMzjld.CurrentRow.Cells[1].Value.ToString();
            string  patID = dgvMzjld.CurrentRow.Cells[0].Value.ToString();
            MZZJ_SZ form1 = new MZZJ_SZ(mzID, patID);

            form1.ShowDialog();
        }
Beispiel #2
0
 private void button1_Click(object sender, EventArgs e)
 {
     if (dataGridView1.Rows.Count == 0)
     {
         MessageBox.Show("请选择病人!");
     }
     else
     {
         string  mzjldid = dataGridView1.CurrentRow.Cells[0].Value.ToString();
         string  patID   = dataGridView1.CurrentRow.Cells[1].Value.ToString();
         string  patNAME = dataGridView1.CurrentRow.Cells[2].Value.ToString();
         string  patSEX  = dataGridView1.CurrentRow.Cells[3].Value.ToString();
         string  patAGE  = dataGridView1.CurrentRow.Cells[4].Value.ToString();
         MZZJ_SZ f2      = new MZZJ_SZ(mzjldid, patID);
         f2.ShowDialog();
     }
 }