Exemple #1
0
        protected void listViewUsers_OnItemCommand(object sender, System.Web.UI.WebControls.ListViewCommandEventArgs e)
        {
            if (String.Equals(e.CommandName, "Allow"))
            {
                // Verify that the employee ID is not already in the list. If not, add the
                // employee to the list.
                ListViewDataItem dataItem   = (ListViewDataItem)e.Item;
                string           employeeID =
                    listViewUsers.DataKeys[dataItem.DisplayIndex].Value.ToString();

                if (UserBLL.ActivateUserWith180DaysInacitvity(Int32.Parse(employeeID), this.AccountInfo.UserId))
                {
                    // usrSearchType = SearchType.Recent;

                    pager.SetPageProperties(0, pager.PageSize, false);


                    //Page.DataBind();
                    listViewUsers.DataBind();
                }
            }
        }