aboutsummaryrefslogtreecommitdiff
path: root/src/AddIn/RegistryUtil.cs
diff options
context:
space:
mode:
authorSerghei Cebotari <51533848+schebotar@users.noreply.github.com>2022-02-05 13:18:18 +0300
committerGitHub <noreply@github.com>2022-02-05 13:18:18 +0300
commitad7234fda7927c45e5ca457facae71a4b9be6b31 (patch)
treed9fc89b0e02a5fdc92d54674b7b48ad2d10859e4 /src/AddIn/RegistryUtil.cs
parent180807d749f4eb3a16c1f136d42b90ea2945008f (diff)
parenteb6a28b955b5b179bd40f21dcf1daa6f9337765f (diff)
Merge pull request #15 from schebotar/dev
Dev
Diffstat (limited to 'src/AddIn/RegistryUtil.cs')
-rw-r--r--src/AddIn/RegistryUtil.cs8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/AddIn/RegistryUtil.cs b/src/AddIn/RegistryUtil.cs
index 3ec6f6a..5fe2eea 100644
--- a/src/AddIn/RegistryUtil.cs
+++ b/src/AddIn/RegistryUtil.cs
@@ -1,5 +1,5 @@
using Microsoft.Win32;
-using RehauSku.Forms;
+using RehauSku.Interface;
using System;
using System.IO;
using System.Windows.Forms;
@@ -38,6 +38,12 @@ namespace RehauSku
if (result == DialogResult.OK)
{
string fileName = Dialog.GetFilePath();
+
+ if (string.IsNullOrEmpty(fileName))
+ {
+ throw new Exception("Нет файла шаблона");
+ }
+
priceListPath = fileName;
RootKey.SetValue("PriceListPath", fileName);
return priceListPath;