NicoTing
NicoTing

Reputation: 93

Navigation in NavigationView via MVVM using Prism

Prism UWP: Prism for UWP
NavigationView UWP: NavigationView

I want to apply MVVM on my NavigationView navigation, I found this article: navigation via mvvm but Iam using Prism, so it doesnt solve my problem.

Navigation in prism:

using Prism.Unity.Windows;

NavigationService.Navigate("Main", null);

Upvotes: 0

Views: 325

Answers (1)

Xie Steven
Xie Steven

Reputation: 8621

You could use the Windows Template Studio to create your project and choose the 'Navigation Pane' and 'prism Design pattern'.

Then, you will see the _navigationService in the ShellViewModel class.

You could use it for navigation.

_navigationService.Navigate(pageKey, null);

Upvotes: 1

Related Questions