Exemple #1
0
 protected void ShowError(AppException ex, string title)
 {
     Deployment.Current.Dispatcher.BeginInvoke(() =>
     {
         MessageBoxResult result = T360ViewUtlity.Handle(CultureManager.Instance, ex, title);
         if (result == MessageBoxResult.OK || result == MessageBoxResult.None)
         {
             SetFocus();
         }
         if (T360ErrorCodes.AppSessionExpired.Equals(ex.ErrorCodes[0].Code))
         {
             RedirectToLogin();
         }
     });
 }
Exemple #2
0
 protected void ShowError(AppException ex)
 {
     if (ex.ErrorCodes.Count == 1 && T360ErrorCodes.UnableToConnectServer.Equals(ex.ErrorCodes[0].Code))
     {
         ShowError(ex, "Network Error");
         return;
     }
     if (ex.ErrorCodes.Count == 1 && T360ErrorCodes.AppSessionExpired.Equals(ex.ErrorCodes[0].Code))
     {
         ShowError(ex, "Session Expired");
         return;
     }
     Deployment.Current.Dispatcher.BeginInvoke(() =>
     {
         MessageBoxResult result = T360ViewUtlity.Handle(CultureManager.Instance, ex);
         if (result == MessageBoxResult.OK || result == MessageBoxResult.None)
         {
             SetFocus();
         }
     });
 }