Aura.UI
Aura.UI copied to clipboard
How to bind AuraTabView Items to Observable Collection
Hello,
i'm currently trying to use the NAvigationView for one of our Apps main menu. The menu items are stored in an obervable collection and are menu groups and menu elements which belong to one group. Till now, we're using a treeview to show the menu by binding to the collection with the following code:
<TreeView x:Name="tvwMainMenu" Width="250" Grid.Column="0" Items="{Binding MenuElements}">
<TreeView.DataTemplates>
<TreeDataTemplate DataType="caocore:CNavigationGroup" ItemsSource="{Binding NavigationElements}">
<StackPanel Orientation="Horizontal">
<Image Source="{Binding Icon, Converter={StaticResource BitmapConverter}}" />
<TextBlock Text="{Binding Name}" />
</StackPanel>
</TreeDataTemplate>
<DataTemplate DataType="caocore:CNavigationElement">
<StackPanel Orientation="Horizontal">
<Image Source="{Binding Icon, Converter={StaticResource BitmapConverter}}" />
<TextBlock Text="{Binding Name}" />
</StackPanel>
</DataTemplate>
</TreeView.DataTemplates>
</TreeView>
Could you please give me a hint, how to bind to the NavigationView?
BR
Hello,
i'm currently trying to use the NAvigationView for one of our Apps main menu. The menu items are stored in an obervable collection and are menu groups and menu elements which belong to one group. Till now, we're using a treeview to show the menu by binding to the collection with the following code:
<TreeView x:Name="tvwMainMenu" Width="250" Grid.Column="0" Items="{Binding MenuElements}"> <TreeView.DataTemplates> <TreeDataTemplate DataType="caocore:CNavigationGroup" ItemsSource="{Binding NavigationElements}"> <StackPanel Orientation="Horizontal"> <Image Source="{Binding Icon, Converter={StaticResource BitmapConverter}}" /> <TextBlock Text="{Binding Name}" /> </StackPanel> </TreeDataTemplate> <DataTemplate DataType="caocore:CNavigationElement"> <StackPanel Orientation="Horizontal"> <Image Source="{Binding Icon, Converter={StaticResource BitmapConverter}}" /> <TextBlock Text="{Binding Name}" /> </StackPanel> </DataTemplate> </TreeView.DataTemplates> </TreeView>
Could you please give me a hint, how to bind to the NavigationView?
BR
MVVM isn't supported, but now I'm working in implement MVVM support, for now you can use controls defined by XAML only.