How to make multiple levels of nested Views in MvvmCross WPF?

37 views Asked by At

I'm trying to create a template for WPF MvvmCross that will have 3 levels of nesting for View. The first View is always unchanged; at this level there should be a menu with buttons. Also at the first level there should be a nested View of the second level. If the first-level view is always unchanged, then several views can be displayed in the container for the second-level view. The second-level view also has a nested container for displaying the 3rd-level view, of which there can also be several. Controlling the display of a nested view should always be done from the view 1 level higher. How can I implement this using NavigationService? So far I've only been able to implement this through regular data binding.

<views:MvxWpfView
    ...
    <StackPanel>
        <Label Content="MainView"/>
        <views:MvxWpfView Name="NestedView" HorizontalAlignment="Stretch" VerticalAlignment="Stretch" ViewModel="{Binding NestedViewModel1}"/>
    </StackPanel>
</views:MvxWpfView>

Although the implementation I performed works, it seems to me that it is not entirely correct. I can't find information on how to do this, and the official documentation is not entirely clear to me at this point. All the examples on the Internet are like dinosaurs, I need it for mvvmCross 9.0+

0

There are 0 answers