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

RadAjaxManager does not work with RadioButtons/RadioButtonLists

3 Answers 119 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Nate Pinchot
Top achievements
Rank 1
Nate Pinchot asked on 28 Mar 2008, 03:15 PM
Hello,
It appears that RadAjaxManager does not work properly with RadioButton or RadioButtonList controls.
If I Have the following code:
    <telerik:RadAjaxManager ID="ramAjax" runat="server" EnableHistory="True" OnAjaxRequest="ramAjax_AjaxRequest"
        <AjaxSettings> 
            <telerik:AjaxSetting AjaxControlID="rbAllWorkOrders"
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="rgSearchResults" LoadingPanelID="ralpLoading" /> 
                    <telerik:AjaxUpdatedControl ControlID="pageTime" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
            <telerik:AjaxSetting AjaxControlID="rbMyWorkOrders"
                <UpdatedControls> 
                    <telerik:AjaxUpdatedControl ControlID="rgSearchResults" LoadingPanelID="ralpLoading" /> 
                    <telerik:AjaxUpdatedControl ControlID="pageTime" /> 
                </UpdatedControls> 
            </telerik:AjaxSetting> 
        </AjaxSettings> 
    </telerik:RadAjaxManager> 
 
 
            <asp:RadioButton runat="server" ID="rbAllWorkOrders" GroupName="rbgWorkOrderFilter" Text="All Work Orders" AutoPostBack="True" OnCheckedChanged="filter_ValueChanged" Checked="True" /> 
            <asp:RadioButton runat="server" ID="rbMyWorkOrders" GroupName="rbgWorkOrderFilter" Text="My Work Orders" AutoPostBack="True" OnCheckedChanged="filter_ValueChanged" /> 
 


When the page loads, the "All Work Orders" RadioButton will be selected by default. If you click the "My Work Orders" button the RadAjaxManager will "trigger" an "ajax postback" causing the loading panel to display and filter_ValueChanged will get called. If you then click "All Work Orders" after that, the RadAjaxManager will not trigger anything, the event will not get called and the loading panel does not display.
The same holds true for setting a "default selected" option in a RadioButtonList. If the AjaxSetting is removed from the RadAjaxManager for these RadioButton controls or RadioButtonList control everything works as expected, however a postback is caused which is why I want to use RadAjaxManager.
Please help.

3 Answers, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 31 Mar 2008, 12:55 PM
Hello Nate,

Please find an attached sample project, which shows the correct behavior of RadioButtons ajaxified with RadAjaxManager. Let us know what the difference in your case is.

Greetings,
Maria Ilieva
the Telerik team

Instantly find answers to your questions at the new Telerik Support Center
0
Nate Pinchot
Top achievements
Rank 1
answered on 31 Mar 2008, 08:10 PM
Apparently the trick is including the ControlID of the RadioButtons or RadioButtonList in the AjaxUpdatedControl of itself. Thanks.
0
Developer
Top achievements
Rank 1
answered on 24 Sep 2010, 04:26 PM
Quick update as was facing same problem, problem is gone and we do not need to have RadioButtonList's ID as an updated control, but if we set ClientIDMode as "static" the problem arises again, so if we remove that attribute, there's no problem.

Regards.
Tags
Ajax
Asked by
Nate Pinchot
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Nate Pinchot
Top achievements
Rank 1
Developer
Top achievements
Rank 1
Share this question
or