MenuItem in ToolBar

3 posts, 0 answers
  1. Ivo
    Ivo avatar
    3 posts
    Member since:
    Dec 2018

    Posted 07 Jan Link to this post

    Hi, i want to have also "MenuItem" in ToolBar besides normal Buttons. I achieved to do it, but the MenuItem is never opened. Is it necessary to do something more. Or is there any other short way to implement this behavior?

    Here it is my xaml

          <telerik:RadToolBar x:Name="toolBar" FocusManager.IsFocusScope="False" HorizontalAlignment="Stretch" Margin="-1 -2 -1 0" BorderBrush="{StaticResource W Grey}" AutoHideOverflowButton="True">
            <telerik:RadButton Margin="2" Command="{Binding LoginCommand}" Content="Login" />
            <telerik:RadButton Margin="2" Command="{Binding LogoutCommand}" Content="Logout" />
            <telerik:RadMenuItem Margin="2">
              <telerik:RadMenuItem Margin="2"  Header="Online Change Compile" Command="{Binding OnlineChangeCompileCommand}">
                <Image Source="../Resources/Images/Toolbar/Icons.16x16.OnlineChangeCompile.png" Stretch="None" />
              </telerik:RadMenuItem>
              <telerik:RadMenuItem Margin="2" Header="Full Compile" Command="{Binding FullCompileCommand}">
                <Image Source="../Resources/Images/ToolBar/Icons.16x16.FullCompile.png" Stretch="None" />
              </telerik:RadMenuItem>
              <telerik:RadMenuItem Margin="2" Header="Full Deploy" Command="{Binding FullDeployCommand}" />
              <telerik:RadMenuItem Margin="2" Header="Online Change Deploy" Command="{Binding OnlineChangeDeployCommand}" />
              <telerik:RadMenuItem.Header>
                <StackPanel Orientation="Horizontal">
                  <Image Margin="0" Source="../Resources/Images/Icons.16x16.OpenContextMenu.png" Stretch="None"  Height="16" Width="16" Visibility="{Binding OpenContextMenuVisibility}"/>
                  <TextBlock Text="Action" />
                </StackPanel>
              </telerik:RadMenuItem.Header>
            </telerik:RadMenuItem>
          </telerik:RadToolBar>

     

    Thanks, Ivo

  2. Vladimir Stoyanov
    Admin
    Vladimir Stoyanov avatar
    420 posts

    Posted 08 Jan Link to this post

    Hello Ivo,

    Thank you for the provided code snippet.

    Please, note that the RadMenuItems are designed to work with the RadMenu control. Can you try placing the RadMenuItems inside a RadMenu?

    Regards,
    Vladimir Stoyanov
    Progress Telerik
    Get quickly onboarded and successful with your Telerik and/or Kendo UI products with the Virtual Classroom free technical training, available to all active customers. Learn More.
  3. Ivo
    Ivo avatar
    3 posts
    Member since:
    Dec 2018

    Posted 09 Jan in reply to Vladimir Stoyanov Link to this post

    Yes i added RadMenu To Toolbar ... thanks
Back to Top