public void Client_LogInCompleted(object sender, LogInCompletedEventArgs e) { Device.BeginInvokeOnMainThread( async() => { if (e.Error != null) { await DisplayAlert("An Error", e.Error.ToString(), "Exit"); } else if (e.Cancelled == true) { await DisplayAlert("Event Cancelled", "Cancelled", "Exit"); } else { Person p = e.Result; if (p == null) { await DisplayAlert("Login Failed", "Login in error", "Exit"); } else { App.PersonApp = p; Navigation.InsertPageBefore(new TabPage(), this); await Navigation.PopAsync(); } } } ); }
private void OnBuildFacadeLogInCompleted(object sender, LogInCompletedEventArgs e) { if (e.IsSucceeded) { LoadBuildList(); } else { MessageBox.Show("User Not Authorized!"); } }
void _client_LogInCompleted(object sender, LogInCompletedEventArgs e) { this.LoginStatus += "."; if (e.Error == null && e.Result != null) { this.LoginStatus += "."; this.No = e.Result.No; this.Address = e.Result.Address; this.City = e.Result.City; this.CountryCode = e.Result.CountryCode; this.IsCompany = e.Result.Company; this.PostalCode = e.Result.PostalCode; this.Name = e.Result.Name; this.Balance = e.Result.Balance; this.LoginStatus = "Logged in successfully."; this.UserLogged = true; if (this.Email == e.Result.Email) { this.LoadLocalData(); } else { this.Email = e.Result.Email; this.ReloadData(); } } else if (e.Error != null) { this.LoginStatus = e.Error.Message; this.Pass = null; this.UserLogged = false; } else { this.LoginStatus = "Wrong email or password!"; this.Pass = null; this.UserLogged = false; } }