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

Calling an update panel from another

1 Answer 34 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Debashis Pyne
Top achievements
Rank 1
Debashis Pyne asked on 09 Aug 2010, 01:45 PM
Hi,

I have 2 panels in an aspx page.
Panel1 - has 1 radiobuttonlist with Yes and No as options
Panel 2 - has 2 textboxes.

I want when Yes from radiobuttonlist is selected - the panel 2 to be displayed and the same to be hdden with No is selected.

The following the code i am using in aspx page:

<telerik:RadAjaxManager ID="RadAjaxManager2" runat="server">
    <AjaxSettings>     
      </telerik:AjaxSetting>
      <telerik:AjaxSetting AjaxControlID="pnlRadioButtons">
        <UpdatedControls>
          <telerik:AjaxUpdatedControl ControlID="pnlRadioButtons" />
        </UpdatedControls>
      </telerik:AjaxSetting>
      <telerik:AjaxSetting AjaxControlID="pnlMiddleData">
        <UpdatedControls>
          <telerik:AjaxUpdatedControl ControlID="pnlMiddleData" />
        </UpdatedControls>
      </telerik:AjaxSetting>
    </AjaxSettings>
  </telerik:RadAjaxManager>


The following is the C# code:

protected void RadBtnSystemUser_SelectedIndexChanged(object sender, EventArgs e)
    {
        if (RadBtnSystemUser.SelectedValue.ToString() == "1")
        {
            pnlMiddleData.Visible = true;
            reqFldUserId.Enabled = true;
        }
        else
        {
            pnlMiddleData.Visible = false;
            reqFldUserId.Enabled = false;
        }
    }

This throws an error saying that since are in 2 seperate update panels an error occured.

Is this possible?
Please help.

--
Regards,
Debashis

1 Answer, 1 is accepted

Sort by
0
Maria Ilieva
Telerik team
answered on 10 Aug 2010, 02:52 PM
Hello,

Could you please elaborate a bit more in your scenario? Are the controls pnlMiddleData and pnlRadioButtons RadAjaxPanela or asp UpdatePanela. Please note that you could not add RadAjaxPanels or asp UpdatePanels into the RadAjaxManager settings.

Kind regards,
Maria Ilieva
the Telerik team

Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
Tags
Ajax
Asked by
Debashis Pyne
Top achievements
Rank 1
Answers by
Maria Ilieva
Telerik team
Share this question
or