4,038 questions
NavigatedToEventArgs
Giorgio Sfiligoi
391
Reputation points
Environment: MAUI app for Android.
When I navigate to a certain page, I would like to know what was the previous page.
I therefore tried:
protected override void OnNavigatedTo(NavigatedToEventArgs args)
{
base.OnNavigatedTo(args);
Debug.WriteLine("OnNavigatedTo");
}
However, the NavigatedToEventArgs does not expose any property o method that tells me where we are navigating from.
By inspecting 'args' with the debugger, I find that it contains:
Non public members: PreviousPage
which indeed addresses my question - but it appears I cannot access it programmatically?
Developer technologies | .NET | .NET MAUI
Sign in to answer