Created
May 3, 2017 23:47
-
-
Save hminaya/c7f0529253cecd0228949f8d0b16aa76 to your computer and use it in GitHub Desktop.
PRISM - DestinationPageViewModelWithParams
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public class DestinationPageViewModel | |
{ | |
INavigationService _navigationService; | |
public DestinationPageViewModel(INavigationService navigationService) | |
{ | |
BackCommand = new DelegateCommand(OnBack); | |
_navigationService = navigationService; | |
} | |
void OnNavigate() | |
{ | |
var pars = new NavigationParameters(); | |
pars.Add("id", Title); | |
_navigationService.NavigateAsync("DestinationPage", pars); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment