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

RadTabstrip on Content Page

3 Answers 66 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
Sean
Top achievements
Rank 1
Sean asked on 10 Dec 2008, 12:37 AM
I am attempting to dynamically load a usercontrol that contains a grid on a pageview. The loading of the control is no problem. I have the RadTabstrip "autopostback" property set to true and I load the usercontrol in the pageload event. The grid contains a straightforward hyperlink column that launches an edit form via javascript. This is straight from your examples. The problem arises when I try and ajaxify the Tabstrip/Multipage. If I select the tabstrip to update the mulipage from the ajaxmanagerproxy the usercontrol loads fine but it breaks the edit column. I get and "Object expected" javascript error. When I remove the ajaxification of the  Tabstrip/Multipage and allow a full postback the usercontrol with grid and the edit column work as expected. It launches the editform radwindow.

3 Answers, 1 is accepted

Sort by
0
Atanas Korchev
Telerik team
answered on 10 Dec 2008, 09:41 AM
Hi Sean,

Please make sure you wrap any <script> tags in the user control inside RadScriptBlock control. This is required so the script blocks are evaluated after loading the control with ajax. Here is an example

<telerik:RadScriptBlock runat="server" ID="RadScript1">
    <script type="text/javascript">
          function MyFunction()
          {
          }
    </script>
</telerik:RadScriptBlock>

I hope this helps,
Albert
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
0
Sean
Top achievements
Rank 1
answered on 10 Dec 2008, 03:01 PM
You pointed me in the right direction, thanks. I had "RadCodeBlock" around my javascript instead of "RadScriptBlock"!!!
0
Atanas Korchev
Telerik team
answered on 10 Dec 2008, 03:05 PM
Hi Sean,

The example you have posted is for RadControls for ASP.NET Classic. IT is using the ClientScript object which will not work in ASP.NET Ajax scenarios. Please use the ScriptManager class for that purpose - ScriptManager.RegisterStartupScript.

Regards,
Albert
the Telerik team

Check out Telerik Trainer, the state of the art learning tool for Telerik products.
Tags
TabStrip
Asked by
Sean
Top achievements
Rank 1
Answers by
Atanas Korchev
Telerik team
Sean
Top achievements
Rank 1
Share this question
or