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

Ajax Error updating UserControl TabStrip when tab not selected

2 Answers 89 Views
Ajax
This is a migrated thread and some comments may be shown as answers.
Jonathan
Top achievements
Rank 1
Jonathan asked on 12 Dec 2008, 09:31 AM
Hi,

I have a TabStrip on my page where one of the tabs contains a user control which I need to be updated with Ajax when the user selects one of a set of options located outside of the TabStrip.  Selecting one of these options triggers a client-side ajax request to update the User Control within the tab.  This works fine when the tab containing the User Control is selected, but when it is not I get an ajax error because the control is hidden as it is on another tab - the error is that it cannot find the control to update it.  Stopping the ajax request from firing if the required tab is not visible is not an option for me.  The User Control is statically defined on the page within a RadPageView linked to the tab and in the User Control code it adds itself as an updated control to the parent page Ajax Manager.  I need to do this because this User Control will also be dynamically loaded elsewhere on the page and need to be updated by Ajax.

Can you suggest how I can get around the issue of this Ajax error when the User Control is not visible?

Thanks in advance.

2 Answers, 1 is accepted

Sort by
0
Accepted
Sebastian
Telerik team
answered on 15 Dec 2008, 03:52 PM
Hello Jonathan,

Thank you for the explanation.

Can you please check whether the RenderSelectedPageOnly property of the multipage control (associated with the tabstrip) is set to false? Additionally, in case you change the value of the Visible property of the user control dynamically, consider setting it to true at all times to expose it for the ajax manager.

Let me know whether this helps or if I am leaving something from your logic out.

Best regards,
Sebastian
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Jonathan
Top achievements
Rank 1
answered on 17 Dec 2008, 03:08 PM
Hi Sebastian,

Sorry for the delay in replying.  Setting that property to false was enough to solve my issue.

Thanks for your help.
Tags
Ajax
Asked by
Jonathan
Top achievements
Rank 1
Answers by
Sebastian
Telerik team
Jonathan
Top achievements
Rank 1
Share this question
or