From 86656d85cafbf48a1e2f5583de4d1ffe66c3fa55 Mon Sep 17 00:00:00 2001 From: Alexander Date: Sat, 28 Sep 2019 22:14:24 +0300 Subject: [PATCH] Fixed #28 --- Crypto Notepad/MainForm.cs | 22 ++++++++++++++++++++-- 1 file changed, 20 insertions(+), 2 deletions(-) diff --git a/Crypto Notepad/MainForm.cs b/Crypto Notepad/MainForm.cs index 0d125e9..9a23a9f 100644 --- a/Crypto Notepad/MainForm.cs +++ b/Crypto Notepad/MainForm.cs @@ -1,4 +1,4 @@ -using IWshRuntimeLibrary; +using IWshRuntimeLibrary; using System; using System.ComponentModel; using System.Diagnostics; @@ -438,7 +438,25 @@ private void CheckForUpdates(bool autoCheck) } catch { - return; + if (autoCheck) + { + mainMenu.Invoke((Action)delegate + { + using (new CenterWinDialog(this)) + { + if (statusPanel.Visible) + { + StatusPanelMessage("update-failed"); + } + else + { + MessageBox.Show("Checking for updates failed:\nConnection lost or the server is busy.", PublicVar.appName, MessageBoxButtons.OK, MessageBoxIcon.Error); + } + } + }); + } + } + } } }