Exemplo n.º 1
0
        async private void btnSignUp_Click(object sender, RoutedEventArgs e)
        {
            var hasCreatedUser = await _signUpViewModel.CreateUser();

            if (hasCreatedUser)
            {
                MainPage mainPage = new MainPage();
                this.NavigationService.Navigate(mainPage);
            }
        }
Exemplo n.º 2
0
 public void SubmitSignUp(object sender, EventArgs e)
 {
     if (viewModel.CreateUser(UsernameEntry.Text, PasswordEntry.Text, FirstNameEntry.Text, LastNameEntry.Text) == false)
     {
         ErrorMessage.Text      = "Username already in use. Please try again.";
         ErrorMessage.IsVisible = true;
     }
     else
     {
         Navigation.PopModalAsync();
     }
 }