public void PagerButtonClick(object sender, EventArgs e) { string arg = e.CommandArgument.ToString(); //string arg = sender.ToString(); switch (arg) { case "next": //The next Button was Clicked if ((dgcategory.CurrentPageIndex < (dgcategory.PageCount - 1))) { dgcategory.CurrentPageIndex += 1; } break; case "prev": //The prev button was clicked if ((dgcategory.CurrentPageIndex > 0)) { dgcategory.CurrentPageIndex -= 1; } break; case "last": //The Last Page button was clicked dgcategory.CurrentPageIndex = (dgcategory.PageCount - 1); break; default: //The First Page button was clicked dgcategory.CurrentPageIndex = Convert.ToInt32(arg); break; } //selpagecombo() //Now, bind the data! BindCategory(); }
'System.EventArgs' does not contain a definition for 'CommandArgument' and no extension method 'CommandArgument' accepting a first argument of type 'System.EventArgs' could be found (are you missing a using directive or an assembly reference?)
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)