Quantcast
Channel: Xamarin.Forms — Xamarin Community Forums
Viewing all articles
Browse latest Browse all 58056

Changing the current page without affecting navigation stack

$
0
0

I have a Main screen with a list of users. When I select a user, I do:

await Navigation.PushAsync(new Details(userViewModel));

This opens a Details page for that user. Great. Now on thisDetailspage I have a menu that allows you to swap to a different screen, say "Sales".

How can I swap out the Details page with the Sales page so that the back button always takes you back to Main?

On the menu click I have done:

await Navigation.PopAsync();

await Globals.CustomersPage.Navigation.PushAsync(new Sales());

which works, but flashes the Main screen (As expected) before swapping to the Sales screen.


Viewing all articles
Browse latest Browse all 58056

Trending Articles