private void DisplayList(IList <User> LstUser) { try { //Bind the Data GvwUserList.DataSource = LstUser; GvwUserList.DataBind(); } catch { throw; } }
private void ClearControls() { //clear the input controls this.ClearControls(txtEmail); this.ClearControls(txtName); this.ClearControls(txtRole); // this.ClearControls(txtlocation); //Bind the Empty Data. GvwUserList.DataSource = null; GvwUserList.DataBind(); }
private void DisplayList(IList <User> userLst) { try { //Bind the Grid GvwUserList.DataSource = userLst; GvwUserList.DataBind(); if (GvwUserList.Rows.Count > 0) { this.DisplayMessage(string.Empty); spnMessage.InnerHtml = ""; foreach (DataControlField column in GvwUserList.Columns) { column.ItemStyle.Width = Unit.Pixel(100); } List <LblLanguage> lblLanguagelst = null; ILblLanguage mLanguageService = null; lblLanguagelst = new List <LblLanguage>(); mLanguageService = AppService.Create <ILblLanguage>(); mLanguageService.AppManager = ((IAppManager)Session["APP_MANAGER"]); // retrieve lblLanguagelst = mLanguageService.RetrieveLabel(((IAppManager)Session["APP_MANAGER"]).LoginUser.Id, "USERMODULE"); Utility _objUtil = new Utility(); _objUtil.LoadGridLabels(lblLanguagelst, GvwUserList); InitalBind.Visible = false; } else { //Show Message when data is Empty. InitalBind.Visible = true; spnMessage.InnerHtml = AlertNorecord; } } catch { throw; } }
private void DisplayList(IList <Project> projectLst) { try { //Bind the Grid GvwUserList.DataSource = projectLst; GvwUserList.DataBind(); if (GvwUserList.Rows.Count > 0) { this.spnMessage.Visible = false; this.DisplayMessage(string.Empty); if (GvwUserList.HeaderRow != null) { List <LblLanguage> lblLanguagelst = null; ILblLanguage mLanguageService = null; lblLanguagelst = new List <LblLanguage>(); mLanguageService = AppService.Create <ILblLanguage>(); mLanguageService.AppManager = ((IAppManager)Session["APP_MANAGER"]); // retrieve lblLanguagelst = mLanguageService.RetrieveLabel(((IAppManager)Session["APP_MANAGER"]).LoginUser.Id, "PROJECT"); Utility _objUtil = new Utility(); _objUtil.LoadGridLabels(lblLanguagelst, GvwUserList); InitalBind.Visible = false; } } else { //Show No Result Found Message. this.spnMessage.Visible = true; this.InitalBind.Visible = true; this.spnMessage.InnerHtml = NODATAFOUND; } } catch { throw; } }