New to Telerik UI for ASP.NET MVC? Download free 30-day trial

Data Binding

The PanelBar provides support for declaratively defining its items and for local (on the server) and remote (using a DataSource configuration object) binding.

Declaring PanelBar Items

The PanelBar allows you to declare all its items within the helper declaration.

The following example demonstrates how to configure a PanelBar with three levels of hierarchy.

    @(Html.Kendo().PanelBar()
        .Name("panelbar")
        .Items(panelbar =>
        {
            panelbar.Add().Text("My Web Site")
                .Items(root =>
                {
                    root.Add().Text("images")
                        .Items(images =>
                        {
                            images.Add().Text("logo.png");
                            images.Add().Text("body-back.png");
                        });
                    root.Add().Text("about.html");
                    root.Add().Text("contacts.html");
                });
        })
    )

PanelBar Binding

The PanelBar supports the following data-binding approaches:

See Also

In this article