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

[Solved] TabStrip Item Appears in Entire Page VB

0 Answers 42 Views
TabStrip
This is a migrated thread and some comments may be shown as answers.
This question is locked. New answers and comments are not allowed.
Brian
Top achievements
Rank 1
Brian asked on 27 Apr 2011, 11:49 PM
I have placed a Telerik ASP.NET MVC TabStrip on a page
 in my MVC3 test project.

When I click 'TabStrip Item', I want to see
 'Views\Telerik\Index.html' on that tab.  It is appearing in
 the entire page instead.

I return a PartialView from the Telerik Controller, so I'm not
 sure what I'm doing wrong. Thanks for any guidance on this.

These are the four items:
Index View & Controller
Telerik View & Controller

Code:
Views\Home\Index.vbhtml
    @Code
        Dim ts As TabStrip = Html.Telerik.TabStrip.Name("Main TabStrip").Items( _
             Function(items)
                 items.Add.Text("Item 1")
                 items.Add.Text("TabStrip Item").LoadContentFrom("Index", "Telerik")
             End Function)
        ts.Render()
    End Code
 
Controllers\HomeController.vb
    Public Class HomeController
        Inherits System.Web.Mvc.Controller

        Function Index() As ActionResult
             ViewData("Message") = "Welcome to ASP.NET MVC!"
             Return View()
        End Function
 
        Function About() As ActionResult
             Return View()
        End Function
    End Class
 
Views\Telerik\Index.html
    @Code
        Dim PanelBar As PanelBar = _
        Html.Telerik.PanelBar.Name("MyPanelBar").Items( _
            Function(tabstrip)
                tabstrip.Add.Text("ASP.NET MVC").Content( _
                Sub()
                @<ul>
                    <li>Pure ASP.NET MVC components</li>
                    <li>Completely Open Source</li>
                </ul>
                End Sub)
                tabstrip.Add.Text("Silverlight").Content( _
                Sub()
                @<ul>
                    <li>Built on Silverlight 3</li>
                    <li>RIA services support</li>
                </ul>
                End Sub)
            End Function)
    PanelBar.Render()
    End Code
 
Controllers\TelerikController.vb
    Namespace UOPN
        Public Class TelerikController
        Inherits System.Web.Mvc.Controller
 
        Function Index() As ActionResult
            Return PartialView()
        End Function
 
        End Class
    End Namespace
Tags
TabStrip
Asked by
Brian
Top achievements
Rank 1
Share this question
or