///<summary> /// Handles the specified exception. ///</summary> public void Handle(Exception e, IExceptionHandlingContext exceptionHandlingContext) { LoadMultipleStudiesException exception = (LoadMultipleStudiesException) e; exceptionHandlingContext.Log(LogLevel.Error, e); exceptionHandlingContext.ShowMessageBox(exception.GetUserMessage()); }
///<summary> /// Handles the specified exception. ///</summary> public void Handle(Exception e, IExceptionHandlingContext exceptionHandlingContext) { LoadMultipleStudiesException exception = (LoadMultipleStudiesException)e; exceptionHandlingContext.Log(LogLevel.Error, e); exceptionHandlingContext.ShowMessageBox(exception.GetUserMessage()); }
public void Handle(Exception e, IExceptionHandlingContext context) { // log this as an error context.Log(LogLevel.Error, e); // report to user context.ShowMessageBox(SR.MessageTimeout, true); }
public void Handle(Exception e, IExceptionHandlingContext context) { // only log this if debugging context.Log(LogLevel.Debug, e); // report to user context.ShowMessageBox(e.Message, true); }
///<summary> /// Handles the specified exception. ///</summary> public void Handle(Exception e, IExceptionHandlingContext exceptionHandlingContext) { exceptionHandlingContext.Log(LogLevel.Error, e); if (e is LoadSopsException) Handle((LoadSopsException)e, exceptionHandlingContext); else if (e is StudyLoaderNotFoundException) Handle((StudyLoaderNotFoundException)e, exceptionHandlingContext); }
public void Handle(Exception e, IExceptionHandlingContext exceptionHandlingContext) { if (e is LoadPriorStudiesException) { exceptionHandlingContext.Log(LogLevel.Error, e); Handle(e as LoadPriorStudiesException, exceptionHandlingContext); } }
public void Handle(Exception e, IExceptionHandlingContext context) { context.Log(LogLevel.Debug, e); context.ShowMessageBox(SR.MessageAccessDenied, true); // this exception is not recoverable // (well, technically it is, but we don't want to encourage retries !!!) context.Abort(); }
public void Handle(Exception e, IExceptionHandlingContext context) { context.Log(LogLevel.Error, e); // if we're known to be in offline mode, then communicate this, otherwise // just report a generic communication error context.ShowMessageBox( Desktop.Application.SessionStatus == SessionStatus.Offline ? SR.MessageEndpointNotFoundOfflineMode : SR.MessageCommunicationError, true); }
public void Handle(Exception e, IExceptionHandlingContext context) { // only log this if debugging context.Log(LogLevel.Debug, e); // report to user context.ShowMessageBox(SR.MessageConcurrentModification, true); // this exception is not recoverable context.Abort(); }
public void Handle(Exception e, IExceptionHandlingContext context) { try { // typically this means authentication failed, which is usually because the session is no longer valid // so inform the desktop of the situation Desktop.Application.InvalidateSession(); } catch (Exception) { // if we get another exception attempting to renew the login, then we just log the original exception // and inform user that there is a problem communicating with server context.Log(LogLevel.Error, e); context.ShowMessageBox(SR.MessageCommunicationError, true); } }
///<summary> /// Handles the specified exception. ///</summary> public void Handle(Exception e, IExceptionHandlingContext exceptionHandlingContext) { exceptionHandlingContext.Log(LogLevel.Error, e); exceptionHandlingContext.ShowMessageBox(SR.MessageNoVisibleDisplaySets); }
public void Handle(Exception e, IExceptionHandlingContext context) { context.Log(LogLevel.Error, e); context.ShowMessageBox(SR.MessageCommunicationError, true); }
public void Handle(Exception e, IExceptionHandlingContext context) { context.Log(LogLevel.Error, e); context.ShowMessageBox(e.Message, true); }