diff --git a/PKHeX.WinForms/Subforms/SAV_Database.cs b/PKHeX.WinForms/Subforms/SAV_Database.cs index c70aaeb63..31ac1ba0a 100644 --- a/PKHeX.WinForms/Subforms/SAV_Database.cs +++ b/PKHeX.WinForms/Subforms/SAV_Database.cs @@ -79,7 +79,17 @@ public SAV_Database(PKMEditor f1, SAVEditor saveditor) // Load Data B_Search.Enabled = false; L_Count.Text = "Loading..."; - new Task(LoadDatabase).Start(); + var task = new Task(LoadDatabase); + task.ContinueWith(z => + { + if (!z.IsFaulted) + return; + Invoke((MethodInvoker)(() => L_Count.Text = "Failed.")); + if (z.Exception == null) + return; + WinFormsUtil.Error("Loading database failed.", z.Exception.InnerException ?? new Exception(z.Exception.Message)); + }); + task.Start(); Menu_SearchSettings.DropDown.Closing += (sender, e) => {