private void GetUserFollowerView(int AccountID) { var _clsGetUserFollower = new BllUser(); var _dtGetUserFollwer = _clsGetUserFollower.GetUserEdit(AccountID); if (_dtGetUserFollwer != null && _dtGetUserFollwer.Rows.Count > 0) { lbFullName.Text = _dtGetUserFollwer.Rows[0]["FullName"].ToString(); } }
private void GetUserEdit() { var _clsGetUser = new BllUser(); if (Session["login"] != null && Session["UserName"] != null && Session["AccountID"] != null) { var _dtGetUser = _clsGetUser.GetUserEdit(int.Parse(Session["AccountID"].ToString())); if (_dtGetUser != null && _dtGetUser.Rows.Count > 0) { lbID.Text = _dtGetUser.Rows[0]["AccountID"].ToString(); txtFullName.Value = _dtGetUser.Rows[0]["FullName"].ToString(); txtEmail.Value = _dtGetUser.Rows[0]["Email"].ToString(); txtCellPhone.Value = _dtGetUser.Rows[0]["CellPhone"].ToString(); txtBirthday.Value = _dtGetUser.Rows[0]["Birthday"].ToString(); if (String.IsNullOrEmpty(_dtGetUser.Rows[0]["DateBegin"].ToString()) || _dtGetUser.Rows[0]["DateBegin"] == DBNull.Value) { lbDateBegin.Text = DateTime.Now.ToString(); } else { lbDateBegin.Text = _dtGetUser.Rows[0]["DateBegin"].ToString(); } if (String.IsNullOrEmpty(_dtGetUser.Rows[0]["User_Image"].ToString()) || _dtGetUser.Rows[0]["User_Image"] == DBNull.Value) { lbPathImg.Text = string.Empty; } else { lbPathImg.Text = _dtGetUser.Rows[0]["User_Image"].ToString(); } if (_dtGetUser.Rows[0]["Gender"].ToString() == "Nam") { rdMade.Checked = true; rdFeMade.Checked = false; } else { rdMade.Checked = false; rdFeMade.Checked = true; } if (String.IsNullOrEmpty(_dtGetUser.Rows[0]["Country_ID"].ToString()) || _dtGetUser.Rows[0]["Country_ID"] == DBNull.Value) { drCountry.SelectedIndex = -1; } else { drCountry.SelectedValue = _dtGetUser.Rows[0]["Country_ID"].ToString(); } if (String.IsNullOrEmpty(_dtGetUser.Rows[0]["Language_ID"].ToString()) || _dtGetUser.Rows[0]["Language_ID"] == DBNull.Value) { drLanguage.SelectedIndex = -1; } else { drLanguage.SelectedValue = _dtGetUser.Rows[0]["Language_ID"].ToString(); } } } }