private void bindData() { PenjaminanDataset.KaryawanRow dr = Karyawan.selectKaryawanByID(eID); Models.PenjaminanDatasetTableAdapters.DivisiTableAdapter ta = new Models.PenjaminanDatasetTableAdapters.DivisiTableAdapter(); DropDownList1.DataSource = (PenjaminanDataset.DivisiDataTable)ta.GetDataByID(dr.DivisiID); DropDownList1.DataBind(); txtName.Value = dr.Nama.ToString(); txtAlamat.Value = dr.Alamat.ToString(); }
private void bindData() { PenjaminanDataset.UserProfileRow dr = UserProfile.selectUserProfileByID(eID); Models.PenjaminanDatasetTableAdapters.u_roleTableAdapter taRole = new Models.PenjaminanDatasetTableAdapters.u_roleTableAdapter(); Models.PenjaminanDatasetTableAdapters.DivisiTableAdapter ta = new Models.PenjaminanDatasetTableAdapters.DivisiTableAdapter(); DropDownList1.DataSource = (PenjaminanDataset.DivisiDataTable)ta.GetDataByID(Convert.ToInt16(dr.division)); RoleList.DataSource = (PenjaminanDataset.u_roleDataTable)taRole.GetDataRoleByID(Convert.ToInt16(dr.role)); DropDownList1.DataBind(); RoleList.DataBind(); txtUsername.Value = dr.username.ToString(); txtPassword.Value = dr.password.ToString(); //txtRole.Value = dr.role.ToString(); //txtDivision.Value = dr.division.ToString(); }