From 01d98db1161e9971506f843017fe4aa1cc6a118e Mon Sep 17 00:00:00 2001 From: Daniel Date: Fri, 23 Dec 2022 01:13:22 +0400 Subject: [PATCH] =?UTF-8?q?=D0=B4=D0=BE=D0=BF=D0=B8=D1=81=D0=B0=D0=BB=20?= =?UTF-8?q?=D0=B8=D1=81=D0=BA=D0=BB=D1=8E=D1=87=D0=B5=D0=BD=D0=B8=D0=B5?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- WinFormsApp1/FormMapWithSetTraktor.cs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/WinFormsApp1/FormMapWithSetTraktor.cs b/WinFormsApp1/FormMapWithSetTraktor.cs index ece47e0..d5fd96e 100644 --- a/WinFormsApp1/FormMapWithSetTraktor.cs +++ b/WinFormsApp1/FormMapWithSetTraktor.cs @@ -160,11 +160,16 @@ namespace WinFormsApp1 MessageBox.Show("Не удалось удалить объект"); } } - catch (Exception ex) + catch (TraktorNotFoundException ex) { _logger.LogWarning("Ошибка удаления: {0}", ex.Message); MessageBox.Show($"Ошибка удаления: {ex.Message}"); } + catch (Exception ex) + { + _logger.LogWarning("Неизвестная ошибка удаления: {0}", ex.Message); + MessageBox.Show($"Неизвестная ошибка: {ex.Message}"); + } } private void ButtonShowStorage_Click(object sender, EventArgs e)