Unplanned
Last Updated: 05 Apr 2018 14:15 by Attila Antal
ADMIN
Attila Antal
Created on: 05 Apr 2018 14:07
Category: Grid
Type: Bug Report
0
ChangePageSize event does not fire for DetailTables in RadGrid
Workaround:
Using the Page_Load event handler, verify which control has initiated the postback as well check whether the Event argument is PageSize.

    protected void Page_Load(object sender, EventArgs e)
    {
        if (IsPostBack && Request.Params["__EVENTTARGET"].StartsWith(RadGrid1.UniqueID))
        {
            // check whether the command was PageSizeChange
            if (Request.Params["__EVENTARGUMENT"].Contains("PageSize;"))
            {
                string[] details = Request.Params["__EVENTARGUMENT"].Split(';');
                GridTableView tableView = FindControl(details[0].Replace("FireCommand:", "")) as GridTableView;
                int newPageSize = int.Parse(details[2]);
                Label1.Text += "TableView Name: " + tableView.Name + ", NewPageSize: " + newPageSize+"<br />";
            }
        }
    }
0 comments