private void btnAddrecordDetail_Click(object sender, EventArgs e) { FormPatientRecord fpr = new FormPatientRecord(Convert.ToInt32(txtHN.Text), cbGender.SelectedValue.ToString()); fpr.ShowDialog(); getDataPatientRecord(); }
private void gvPatientRecord_CellContentClick(object sender, DataGridViewCellEventArgs e) { if (gvPatientRecord.Columns[e.ColumnIndex].Name == "clmBtnEdit") { string a = gvPatientRecord.CurrentRow.Cells[1].Value.ToString(); FormPatientRecord fpr = new FormPatientRecord(Convert.ToInt16(gvPatientRecord.CurrentRow.Cells[1].Value.ToString()), Convert.ToInt32(txtHN.Text), cbGender.SelectedValue.ToString()); fpr.ShowDialog(); getDataPatientRecord(); } }