private void GetDataFrom() { pSV_SinhVienInfo.GioiTinh = cmbGioiTinh.EditValue.ToString() == "0" ? false : true; pSV_SinhVienInfo.IDDM_DanToc = int.Parse("0" + cmbDanToc.EditValue); if (dtpNgaySinh.EditValue != null) { pSV_SinhVienInfo.NgaySinh = DateTime.Parse(dtpNgaySinh.EditValue.ToString()); } else { pSV_SinhVienInfo.NgaySinh = DateTime.Parse("1/1/1900"); } pSV_SinhVienInfo.NgayVaoDang = DateTime.Parse("1/1/1900"); pSV_SinhVienInfo.NgayVaoDoan = DateTime.Parse("1/1/1900"); pSV_SinhVienInfo.NgayCapCMND = DateTime.Parse("1/1/1900"); pSV_SinhVienInfo.HoVaTen = txtHoVaTen.Text; pSV_SinhVienInfo.MaSinhVien = txtMaSV.Text; pSV_SinhVienInfo.SoCMND = txtSoCMT.Text; pSV_SinhVienInfo.DienThoaiDiDong = txtDienThoai.Text; pSV_SinhVienInfo.Email = txtEmail.Text; pSV_SinhVienInfo.Ten = cls.GetTen(txtHoVaTen.Text); }
private void GetDataFromForm() { pGiaoVienInfo.IDNS_DonVi = int.Parse(cmbIDDonVi.EditValue.ToString()); pGiaoVienInfo.GiangDay = chkGiangDay.Checked; pGiaoVienInfo.GioiTinh = cmbGioiTinh.EditValue.ToString() == "0" ? false : true; pGiaoVienInfo.IDDM_DanToc = int.Parse("0" + cmbDanToc.EditValue); if (dtpNgaySinh.EditValue != null) { pGiaoVienInfo.NgaySinh = DateTime.Parse(dtpNgaySinh.EditValue.ToString()); } else { pGiaoVienInfo.NgaySinh = DateTime.Parse("1/1/1900"); } pGiaoVienInfo.HoTen = txtHoVaTen.Text; pGiaoVienInfo.Ten = cls.GetTen(txtHoVaTen.Text.Trim()); pGiaoVienInfo.TenVietTat = txtTenVietTat.Text; pGiaoVienInfo.MaGiaoVien = txtMaGiaoVien.Text; pGiaoVienInfo.SoCMND = txtSoCMND.Text; pGiaoVienInfo.NgayCap = DateTime.Parse("1/1/1900"); pGiaoVienInfo.DienThoai = txtSoDienThoai.Text; pGiaoVienInfo.Email = txtEmail.Text; }