diff --git a/src/Interface/Dialog.cs b/src/Interface/Dialog.cs index 6b05dc8..f8ab645 100644 --- a/src/Interface/Dialog.cs +++ b/src/Interface/Dialog.cs @@ -58,9 +58,11 @@ namespace RehauSku.Interface workbook.Close(false); } - string fileName = dialog.FileName; - - workbook.SaveAs(fileName); + else + { + string fileName = dialog.FileName; + workbook.SaveAs(fileName); + } } } }