private void dtgThongTinPhong_CellClick(object sender, DataGridViewCellEventArgs e) { /*txtSoPhong.Text = dtgThongTinPhong.Rows[e.RowIndex].Cells[0].Value.ToString().Trim(); * txtGia.Text = dtgThongTinPhong.Rows[e.RowIndex].Cells[3].Value.ToString().Trim(); * cmbLoaiPhong.Text = dtgThongTinPhong.Rows[e.RowIndex].Cells[1].Value.ToString().Trim(); * Entity.Phong p = new Entity.Phong(int.Parse(txtSoPhong.Text),cmbLoaiPhong.Text, * Boolean.Parse(dtgThongTinPhong.Rows[e.RowIndex].Cells[2].Value.ToString()), * Double.Parse(txtGia.Text)); * phong = p;*/ CellClickTableContent.cellClickTableDatPhong(txtSoPhong, txtGia, cmbLoaiPhong, ref phong, dtgThongTinPhong, e.RowIndex); MessageBox.Show(phong.LoaiPhong); }
private void dtgDanhSachNhanVien_CellClick(object sender, DataGridViewCellEventArgs e) { CellClickTableContent.cellClickTableNhanVien(txtManv, txtTennv, txtDiaChi, txtSDT, cmbChucVu, dtpNgaySinh, cmbGioiTinh, txtTaiKhoan, txtMatKhau, ref nhanVien, dtgDanhSachNhanVien, e.RowIndex); }