I know that there are many topics related to this issue, but I could not find a solution that is ideal for my problem ... maybe not?
At the moment, I have a UserControl that contains a navigation that allows the user to switch between different screens. These screens are defined in the Resources part of my UserControl as a DataTemplate .
Something like that:
<DataTemplate TargetType={x:Type vm:ViewModel1}> ... </DataTemplate> <DataTemplate TargetType={x:Type vm:ViewModel2}> ... </DataTemplate> <DataTemplate TargetType={x:Type vm:ViewModel3}> ... </DataTemplate>
Ok, and I want to do this in order to place these DataTemplates in a separate XAML file and link this file to a part of the UserControl resources. Should I really make this new XAML resource dictionary globally available in my application (adding it to App.xaml resources) or is there another / better way?
seveves
source share