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

TabStrip / Load on Demand RadPageView in Sharepoint 2010

3 Answers 41 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
Ronak
Top achievements
Rank 1
Ronak asked on 16 Jul 2012, 06:18 PM
Hi Telerik team,
i am trying to create same application explain in this article http://demos.telerik.com/aspnet-ajax/tabstrip/examples/applicationscenarios/loadondemand/defaultcs.aspx in SharePoint 2010 using webpart.As per article i have created VisualWebpart which will create two Tabs and once you click on tab it will load UserControl.it is working fine without ajax settings if i try to implement ajax setting its not working.
Here is HTML Markup for WorkspaceTabs.ascx.
<script type="text/javascript">
    function onTabSelecting(sender, args) {
        if (args.get_tab().get_pageViewID()) {
            args.get_tab().set_postBack(false);
        }
    }
</script>
<Telerik:RadAjaxLoadingPanel ID="radajaxloadingPanel" runat="server" Skin="Default" />
<div id="Tabs">
    <Telerik:RadMultiPage ID="radWorkspaceMultiPage"
                          runat="server"
                          SelectedIndex="0"
                          OnPageViewCreated="radWorkspaceMultiPage_PageViewCreated">
    </Telerik:RadMultiPage>
    <Telerik:RadTabStrip ID="radWorkspaceTab"
                         SelectedIndex="0"
                         runat="server"
                         MultiPageID="radWorkspaceMultiPage"
                         OnTabClick="radWorkspaceTab_TabClick"
                         OnClientTabSelecting="onTabSelecting"
                         >
     </Telerik:RadTabStrip
</div>

Workspace.cs file load above Usercontrol
[ToolboxItemAttribute(false)]
    public class Workspaces : WebPart
    {
        // Visual Studio might automatically update this path when you change the Visual Web Part project item.
        private const string _ascxPath = @"~/_CONTROLTEMPLATES/Connexus/WorkspacesTabs.ascx";
        RadAjaxManager ajaxmgr;
        protected override void OnInit(EventArgs e) {
            base.OnInit(e);
          /*  ajaxmgr = RadAjaxManager.GetCurrent(this.Page);
            if (ajaxmgr == null) {
                ajaxmgr = new RadAjaxManager();
                ajaxmgr.ID = "RadAjaxManager1";
                this.Page.Items.Add(typeof(RadAjaxManager), ajaxmgr);
                Page.Form.Controls.AddAt(0, ajaxmgr);
            } */
            
             
        }
        protected override void CreateChildControls() {
            Control control = Page.LoadControl(_ascxPath);
            Controls.Add(control);
           RadMultiPage radWorkspaceMultiPage = control.FindControl("radWorkspaceMultiPage") as RadMultiPage;
            RadTabStrip radWorkspaceTab = control.FindControl("radWorkspaceTab") as RadTabStrip;
            RadAjaxLoadingPanel loadingPanel = control.FindControl("radajaxloadingPanel") as RadAjaxLoadingPanel;
            ajaxmgr.AjaxSettings.AddAjaxSetting(radWorkspaceTab, radWorkspaceMultiPage,loadingPanel);
           ajaxmgr.AjaxSettings.AddAjaxSetting(radWorkspaceTab, radWorkspaceTab);
           ajaxmgr.AjaxSettings.AddAjaxSetting(radWorkspaceMultiPage, radWorkspaceMultiPage, loadingPanel);
             
        }
    }

Please advise

Thanks
Ronak

3 Answers, 1 is accepted

Sort by
0
Plamen
Telerik team
answered on 19 Jul 2012, 02:48 PM
Hello Ronak,

 
Thank you for contacting Telerik support.

I have inspected the code that you shared but will need some more information in order to be more helpful. Would you please elaborate what exactly do you mean by "not working" -is there some error or something else is happening(or not happening) while performing the load on demand? Would you please provide all the code behind that is used as well so we can test it locally be more helpful while helping you?

Regards,
Plamen
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
0
Ronak
Top achievements
Rank 1
answered on 19 Jul 2012, 04:48 PM
Thanks Plamen  for your reply.it works if i don't try to implement Ajax but its not working if i try to implement as it is explain in that article.
i dont see loadingpanel either.the only difference is i am trying to achieve same thing in sharepoint 2010 using webpart instead of plain asp.net
please advise and let me know how can i send code

Thanks
Ronak
0
Plamen
Telerik team
answered on 24 Jul 2012, 03:40 PM
Hi Ronak,

 
Unfortunately the issue is still not clear. You can send you code via support ticket from your Telerik account.

Regards,
Plamen
the Telerik team
If you want to get updates on new releases, tips and tricks and sneak peeks at our product labs directly from the developers working on the RadControls for ASP.NET AJAX, subscribe to their blog feed now.
Tags
TabStrip
Asked by
Ronak
Top achievements
Rank 1
Answers by
Plamen
Telerik team
Ronak
Top achievements
Rank 1
Share this question
or