/// <summary> /// Creates an instance of ErrorForm and show /// </summary> /// <param name="exception">exception as any</param> /// <param name="category">error category</param> /// <param name="currentLanguageID">current user language</param> public static void ShowError(Exception exception, ErrorCategory category, int currentLanguageID) { ErrorForm form = new ErrorForm(exception, category, currentLanguageID); if (null != MainForm.Singleton && MainForm.Singleton.Visible) form.ShowDialog(MainForm.Singleton); else { form.StartPosition = FormStartPosition.CenterScreen; form.ShowDialog(); } }
/// <summary> /// Creates an instance of ErrorForm and show /// </summary> /// <param name="parent">modal parent</param> /// <param name="exception">exception as any</param> /// <param name="category">error category</param> public static void ShowError(IWin32Window parent, Exception exception, ErrorCategory category) { ErrorForm form = new ErrorForm(exception, category, Forms.MainForm.Singleton.CurrentLanguageID); form.ShowDialog(parent); }
/// <summary> /// Creates an instance of ErrorForm and show /// </summary> /// <param name="parent">modal parent</param> /// <param name="exception">exception as any</param> /// <param name="category">error category</param> /// <param name="currentLanguageID">current user language</param> public static void ShowError(IWin32Window parent, Exception exception, ErrorCategory category, int currentLanguageID) { ErrorForm form = new ErrorForm(exception, category, currentLanguageID); form.ShowDialog(parent); }
/// <summary> /// Creates an instance of ErrorForm and show /// </summary> /// <param name="parent">modal parent</param> /// <param name="exception">exception as any</param> /// <param name="category">error category</param> public static void ShowError(IWin32Window parent, Exception exception, ErrorCategory category) { ErrorForm form = new ErrorForm(exception, category, Forms.MainForm.Singleton.CurrentLanguageID ); form.ShowDialog(parent); }
/// <summary> /// Creates an instance of ErrorForm and show /// </summary> /// <param name="parent">modal parent</param> /// <param name="exception">exception as any</param> public static void ShowError(IWin32Window parent, Exception exception) { ErrorForm form = new ErrorForm(exception, ErrorCategory.NonCritical); form.ShowDialog(parent); }
/// <summary> /// Creates an instance of ErrorForm and show /// </summary> /// <param name="parent">modal parent</param> /// <param name="exception">exception as any</param> /// <param name="category">error category</param> /// <param name="message">friendly header message for the user</param> public static void ShowError(IWin32Window parent, Exception exception, ErrorCategory category, string message) { ErrorForm form = new ErrorForm(exception, message, category); form.ShowDialog(parent); }