protected override async void OnStart() { // Handle when your app starts Account.Token = await Settings.GetTokenAsync(); Account.Password = await Settings.GetPasswordAsync(); Account.Username = Settings.Username; Account.AccountId = Settings.AccountId; MainPage = new RootPage(); }
public RootPage() { InitializeComponent(); Instance = this; SetHasBackButton(this, false); Navigation.PushAsync(AppShell.Instance); if (!App.Instance.Account.IsLogined) { Navigation.PushAsync(LoginPage.Instance); } }