private async void SignUp() { //null or empty field validation, check weather email and password is null or empty if (string.IsNullOrEmpty(Email) || string.IsNullOrEmpty(Password)) { await App.Current.MainPage.DisplayAlert("Empty Values", "Please enter Email and Password", "OK"); } else { //call AddUser function which we define in Firebase helper class var user = await FirebaseHelper.AddUser(Email, Password); //AddUser return true if data insert successfuly if (user) { await App.Current.MainPage.DisplayAlert("SignUp Success", "", "Ok"); //Navigate to Wellcom page after successfuly SignUp //pass user email to welcom page await App.Current.MainPage.Navigation.PushAsync(new WelcomPage(Email)); } else { await App.Current.MainPage.DisplayAlert("Error", "SignUp Fail", "OK"); } } }