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

How can I mix static and dynamic items in Telerik's RadMenu for Silverlight?

1 Answer 67 Views
Menu
This is a migrated thread and some comments may be shown as answers.
Jeff
Top achievements
Rank 1
Jeff asked on 20 Jan 2012, 01:27 AM

I'm using Telerik's controls for Silverlight and I'm trying to get my data bound items to append to the end of my statically defined ones. I'm using the following code right now:

telerikNavigation:RadMenuItem Header="Tag Categories" ItemsSource="{Binding SelectedItem.TagCategories}" 
                           
DisplayMemberPath="Code" >
<telerikNavigation:RadMenuItem Header="Create New" Command="{Binding AddNewTagCategoryCommand}" CommandParameter="{Binding SelectedTagCategory}">
   
<telerikNavigation:RadMenuItem.Icon>
       
<Image Style="{StaticResource ImageAddSmall}" />
   
</telerikNavigation:RadMenuItem.Icon>
</
telerikNavigation:RadMenuItem>
<telerikNavigation:RadMenuItem Header="Manage">
   
<telerikNavigation:RadMenuItem.Icon>
       
<Image Style="{StaticResource ImageEditSmall}"/>
   
</telerikNavigation:RadMenuItem.Icon>
</
telerikNavigation:RadMenuItem>
<telerikNavigation:RadSeparator />

Unfortunately it's overwriting my statically defined items ("Create New" and "Manage") with the ones off of the ItemsSource. Is there some way to get both to place nice together?

1 Answer, 1 is accepted

Sort by
0
Konstantina
Telerik team
answered on 21 Jan 2012, 03:30 PM
Hello Jeffrey,

You cannot mix static and dynamic items - this is two different ways of setting the ItemsSource of the menu. I can suggest you to add the static items in your collection.

Kind regards,
Konstantina
the Telerik team
Explore the entire Telerik portfolio by downloading the Ultimate Collection trial package. Get it now >>
Tags
Menu
Asked by
Jeff
Top achievements
Rank 1
Answers by
Konstantina
Telerik team
Share this question
or