New to Telerik UI for ASP.NET AJAXStart a free 30-day trial

Declaring Items Statically at Design Time

The definition of RadToolBar items can be added to the in-line declaration of the toolbar using the RadToolBar Item Builder. The item builder updates the ASPX or ASCX file to include the list of items and their properties.

You can also directly edit the ASPX or ASCX file by adding items to the section of the RadToolBar declaration. The item declaration might be <telerik:RadToolBarButton .../>, <telerik:RadToolBarDropDown .../>or <telerik:RadToolBarSplitButton ... />.

Example

Add the following inline definition of a toolbar to your ASPX or ASCX file:

ASPNET
<telerik:RadToolBar RenderMode="Lightweight" ID="RadToolBar1" runat="server" Orientation="Horizontal">
    <CollapseAnimation Duration="200" Type="OutQuint" />
    <Items>
        <telerik:RadToolBarButton runat="server" Text="Button 1">
        </telerik:RadToolBarButton>
        <telerik:RadToolBarDropDown runat="server" Text="DropDown 1">
            <Buttons>
                <telerik:RadToolBarButton runat="server" Text="Child Button 1">
                </telerik:RadToolBarButton>
                <telerik:RadToolBarButton runat="server" Text="Child Button 2">
                </telerik:RadToolBarButton>
            </Buttons>
        </telerik:RadToolBarDropDown>
        <telerik:RadToolBarSplitButton runat="server" Text="SplitButton 1">
            <Buttons>
                <telerik:RadToolBarButton runat="server" Text="Child Button 1">
                </telerik:RadToolBarButton>
                <telerik:RadToolBarButton runat="server" Text="Child Button 2">
                </telerik:RadToolBarButton>
            </Buttons>
        </telerik:RadToolBarSplitButton>
    </Items>
</telerik:RadToolBar>

See Also

In this article
ExampleSee Also
Not finding the help you need?
Contact Support