This is a migrated thread and some comments may be shown as answers.

RadListView not Refreshing on Close of RadWindow

1 Answer 120 Views
Window
This is a migrated thread and some comments may be shown as answers.
Rakesh Gupta
Top achievements
Rank 2
Rakesh Gupta asked on 23 Aug 2011, 11:06 AM
Hi All,

I am facing a problem with RadWindow and RadListView.

I want to Rebind Perticular ListView on Parent Page on Close of the RadWindow.

I have used a RadTabStrip in side that i have more than one ListViews. I need to Rebind only perticular ListView. 

I have added a code on RadWindow's Button click :
GetRadWindow().BrowserWindow.refreshGrid(args);
GetRadWindow().close();

Which calls following method on Parent Page:

function refreshGrid(arg)
{
     //var btnName = $get("<%=btn.ClientID%>").name;
     //__doPostBack(btnName, "");
     // Above Two Lines code works fine. But the whole page Postback is called. i need only refresh perticular ListView to Rebind.
      
 
     var ajaxManager = $find("<%= RadAjaxManager1.ClientID %>");
     ajaxManager.ajaxRequest('Refresh');
      
}

cs code:
protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e)
{
     if (e.Argument.ToString() == "Refresh")
     {        
           lstvTask.Rebind();
     }
}


This code doesn't work for me.

Any help will be appreciated.
Thanks in Advance.

--
Thanks & Regards,
Rakesh Gupta



1 Answer, 1 is accepted

Sort by
0
Marin Bratanov
Telerik team
answered on 24 Aug 2011, 09:14 AM
Hi Rakesh,

Can you please explain in greater detail what exactly is not working for you from this code? Is the AJAX request never fired (i.e. the refreshGrid() function is never called by the RadWindow), is the server-side handler not hit, or something else? Please note that there are some limitations in ajaxifying a RadMultiPage - either the entire RadMultiPage should be the updated control, or you can only update separate controls inside. Thus I would also recommend that you examine your AJAX settings - make sure that you include the lstvTask ListView in the UpdatedControls collection of the AJAX setting that has the RadAjaxManager as initiator. You setup should be similar to the following:
<telerik:RadAjaxManager runat="server" ID="RadAjaxManager1" OnAjaxRequest="RadAjaxManager1_AjaxRequest">
    <AjaxSettings>
        <telerik:AjaxSetting AjaxControlID="RadAjaxManager1">
            <UpdatedControls>
                <telerik:AjaxUpdatedControl ControlID="lstvTask" />
            </UpdatedControls>
        </telerik:AjaxSetting>
    </AjaxSettings>
</telerik:RadAjaxManager>


Regards,
Marin
the Telerik team

Thank you for being the most amazing .NET community! Your unfailing support is what helps us charge forward! We'd appreciate your vote for Telerik in this year's DevProConnections Awards. We are competing in mind-blowing 20 categories and every vote counts! VOTE for Telerik NOW >>

Tags
Window
Asked by
Rakesh Gupta
Top achievements
Rank 2
Answers by
Marin Bratanov
Telerik team
Share this question
or