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

controls stop working after first call

3 Answers 83 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
johnathan
Top achievements
Rank 1
johnathan asked on 17 Jan 2009, 07:21 PM
Hi Guys,
 Getting close to having demo ready for client. Have a weird thing happening. Everything on the grid works fine (context menu, grouping etc). Whenever I actually perform an action (grouping context menu etc) the subsequent actions to the controls does nothing. ie i can group once but after that it stops. I am sure it is something simple. Herer is my ajax maager code


<

telerik:RadAjaxManager ID="RadAjaxManager1" runat="server"

 

 

DefaultLoadingPanelID="RadAjaxLoadingPanel1"

 

 

OnAjaxRequest="RadAjaxManager1_AjaxRequest" EnableHistory="True">

 

 

<AjaxSettings>

 

 

<telerik:AjaxSetting AjaxControlID="RadMenu1">

 

 

<UpdatedControls>

 

 

<telerik:AjaxUpdatedControl ControlID="RadMenu1" />

 

 

<telerik:AjaxUpdatedControl ControlID="RadGrid1"

 

 

LoadingPanelID="RadAjaxLoadingPanel1" />

 

 

</UpdatedControls>

 

 

</telerik:AjaxSetting>

 

 

<telerik:AjaxSetting AjaxControlID="RadGrid1">

 

 

<UpdatedControls>

 

 

<telerik:AjaxUpdatedControl ControlID="RadMenu1" />

 

 

<telerik:AjaxUpdatedControl ControlID="RadGrid1"

 

 

LoadingPanelID="RadAjaxLoadingPanel1" />

 

 

</UpdatedControls>

 

 

</telerik:AjaxSetting>

 

 

</AjaxSettings>

 

 

</telerik:RadAjaxManager>

 

3 Answers, 1 is accepted

Sort by
0
johnathan
Top achievements
Rank 1
answered on 17 Jan 2009, 07:24 PM
code behind for ajaxmanager

 

/// <summary>

 

 

/// RadAjaxManager1_AjaxRequest

 

 

/// </summary>

 

 

/// <param name="sender"></param>

 

 

/// <param name="e"></param>

 

 

protected void RadAjaxManager1_AjaxRequest(object sender, AjaxRequestEventArgs e)

 

{

 

if (e.Argument == "Rebind")

 

{

RadGrid1.MasterTableView.SortExpressions.Clear();

RadGrid1.MasterTableView.GroupByExpressions.Clear();

RadGrid1.Rebind();

}

 

else if (e.Argument == "RebindAndNavigate")

 

{

RadGrid1.MasterTableView.SortExpressions.Clear();

RadGrid1.MasterTableView.GroupByExpressions.Clear();

RadGrid1.MasterTableView.CurrentPageIndex = RadGrid1.MasterTableView.PageCount - 1;

RadGrid1.Rebind();

}

}

0
johnathan
Top achievements
Rank 1
answered on 17 Jan 2009, 08:09 PM
Last piece of information... The grid is on a controls page hosted by another aspx page.
0
SamJ
Top achievements
Rank 1
answered on 19 Jan 2009, 06:25 AM
Hi johnathan,

Is your user control dynamically loaded, or it is declaratively added?

I would suggest you to replace the RadAjaxManager in the user control with RadAjaxManagerProxy and place tyhe manager in the main page (or master page if you have one).

Check out this articles and see if it helps.

RadAjaxManager
RadAjaxManagerProxy




Tags
Ajax
Asked by
johnathan
Top achievements
Rank 1
Answers by
johnathan
Top achievements
Rank 1
SamJ
Top achievements
Rank 1
Share this question
or