how to remove back button after pushing new page ?

OmarMohOmarMoh USMember ✭✭

Hi all

my app structure like this [Root page] -> [Register page ] -> [Main page]
now when the user register new account transfer him to main page .without back button on main page
see bellow

app class >
` public partial class App : Application
{
public App()
{
InitializeComponent();

        MainPage = new NavigationPage(new RootPage());
    }

`

root page >
async void new_acc_btn_Clicked(object sender, EventArgs e) { await Navigation.PushAsync(new RegisterPage()); }

register page >

` async void register_btn_Clicked(object sender, EventArgs e)
{
Navigation.InsertPageBefore(new MainPage(), this);

        await Navigation.PopAsync();

    }`

Best Answer

Answers

Sign In or Register to comment.