private void dataGridView1_DoubleClick(object sender, EventArgs e) { DataGridViewRow dr = dgvPatients.SelectedRows[0]; frmPatientRecord frm = new frmPatientRecord(dr); frm.Show(); }
private void btnSelect_Click(object sender, EventArgs e) { if (dgvPatients.SelectedRows.Count > 0) { DataGridViewRow dr = dgvPatients.SelectedRows[0]; frmPatientRecord frm = new frmPatientRecord(dr); frm.Show(); } }