예제 #1
0
 private async void cmdOk_Clicked(object sender, EventArgs e)
 {
     try
     {
         gridProgress.IsVisible = true;
         await Task.Run(async() =>
         {
             await SessionSingleton.LoginResourceOwner(txtEmail.Text, txtPassword.Text);
             IsCancelled = false;
             Device.BeginInvokeOnMainThread(() =>
             {
                 ClosePage();
             });
         });
     }
     catch (Exception ex)
     {
         SessionSingleton.EndSession();
         await App.Current.MainPage.DisplayAlert("Error", ex.Message, "OK");
     }
     finally
     {
         gridProgress.IsVisible = false;
     }
 }
예제 #2
0
 private void cmdOk_Clicked(object sender, EventArgs e)
 {
     SessionSingleton.EndSession();
     ClosePage();
 }