Hello, I've a RadGrid into ASP:Panel but the RadGrid Rebind don't work correctly!
When close modal (RadWindow) or change the page with RadGrid pagination, the grid collapse and don't rebind the data (with debug, the page except the ItemDataBound on Rebind).
-- RAM --
protected void RAM_AjaxRequest(object sender, AjaxRequestEventArgs e)
{
if (e.Argument == "Rebind")
{
RG1.MasterTableView.SortExpressions.Clear();
RG1.MasterTableView.GroupByExpressions.Clear();
RG1.Rebind();
}
else if (e.Argument == "RebindAndNavigate")
{
RG1.MasterTableView.SortExpressions.Clear();
RG1.MasterTableView.GroupByExpressions.Clear();
RG1.MasterTableView.CurrentPageIndex = RG1.MasterTableView.PageCount - 1;
RG1.Rebind();
}
}
-- RAD MANAGER AND JS --
function refreshGrid(arg) {
if (!arg) {
$find("<%= RAM.ClientID %>").ajaxRequest("Rebind");
}
else {
$find("<%= RAM.ClientID %>").ajaxRequest("RebindAndNavigate");
}
}
</script>
</telerik:RadCodeBlock>
<!-- Rad Ajax Manager -->
<telerik:RadAjaxManager ID="RAM" runat="server" OnAjaxRequest="RAM_AjaxRequest">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RAM">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RG1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RG1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RG1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
Why this?
Thanks.
When close modal (RadWindow) or change the page with RadGrid pagination, the grid collapse and don't rebind the data (with debug, the page except the ItemDataBound on Rebind).
-- RAM --
protected void RAM_AjaxRequest(object sender, AjaxRequestEventArgs e)
{
if (e.Argument == "Rebind")
{
RG1.MasterTableView.SortExpressions.Clear();
RG1.MasterTableView.GroupByExpressions.Clear();
RG1.Rebind();
}
else if (e.Argument == "RebindAndNavigate")
{
RG1.MasterTableView.SortExpressions.Clear();
RG1.MasterTableView.GroupByExpressions.Clear();
RG1.MasterTableView.CurrentPageIndex = RG1.MasterTableView.PageCount - 1;
RG1.Rebind();
}
}
-- RAD MANAGER AND JS --
function refreshGrid(arg) {
if (!arg) {
$find("<%= RAM.ClientID %>").ajaxRequest("Rebind");
}
else {
$find("<%= RAM.ClientID %>").ajaxRequest("RebindAndNavigate");
}
}
</script>
</telerik:RadCodeBlock>
<!-- Rad Ajax Manager -->
<telerik:RadAjaxManager ID="RAM" runat="server" OnAjaxRequest="RAM_AjaxRequest">
<AjaxSettings>
<telerik:AjaxSetting AjaxControlID="RAM">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RG1" />
</UpdatedControls>
</telerik:AjaxSetting>
<telerik:AjaxSetting AjaxControlID="RG1">
<UpdatedControls>
<telerik:AjaxUpdatedControl ControlID="RG1" />
</UpdatedControls>
</telerik:AjaxSetting>
</AjaxSettings>
</telerik:RadAjaxManager>
Why this?
Thanks.