Browse Source

Hack to stop FastReports.WPF filling up the logs with stupid error messages

frogsoftware 1 năm trước cách đây
mục cha
commit
1d7ada80ea
1 tập tin đã thay đổi với 4 bổ sung0 xóa
  1. 4 0
      prs.desktop/App.xaml.cs

+ 4 - 0
prs.desktop/App.xaml.cs

@@ -320,6 +320,10 @@ namespace PRSDesktop
 
         private void LogUnhandledException(Exception exception, string source)
         {
+            // Hacky Hack Hack FastReport.WPF throwing errors here
+            if (exception.Message.Contains("Must create DependencySource on same Thread as the DependencyObject."))
+                return;
+            
             var messages = new List<string>();
             var e2 = exception;
             while (e2 != null)