private async void ChangePassword() { var succeeded = await Webaccess.ChangePassword(Token.AccessToken, OldPassword, NewPassword); if (succeeded) { PasswordChangeMessage = "Paswoord is gewijzigd!"; } else { PasswordChangeMessage = "Verkeerd wachtwoord!"; } OldPassword = ""; NewPassword = ""; }
private void Login() { Token = Webaccess.GetToken(UserName, Password); if (Token.IsError) { TokenOk = false; LoginMessage = "Verkeerde combinatie!"; } else { TokenOk = true; LoginMessage = "Ingelogd!"; ApplicationVM appvm = App.Current.MainWindow.DataContext as ApplicationVM; appvm.RefreshAllPages(); } Password = ""; }