/// <summary> /// Checks To see if Email is of a valid type /// </summary> /// <returns>True if email is valid.</returns> private bool isEmailValid() { // TODO Validate Email TemporaryStudent tempStudent = new TemporaryStudent(); tempStudent.RequestInformation(); return(true); }
/// <summary> /// Validates information entered and creates account if possilbe /// This will also log user into new account created. /// </summary> /// <param name="sender"></param> /// <param name="e"></param> private void CreateAccountButtonClicked(object sender, EventArgs e) { if (ValidateCreateAccountFields(EmailField.Text, PasswordField.Text, ConfirmPasswordField.Text)) { TemporaryStudent newStudent = new TemporaryStudent() { Email = EmailField.Text, }; this.Navigation.RemovePage(this.Navigation.NavigationStack.Last()); LogUserIn(newStudent); } }
private async void LogUserIn(TemporaryStudent user) { await Navigation.PushAsync(new StudentMainPage(user)); }