diff --git a/SetUpWindow/SetUpViewModel.vb b/SetUpWindow/SetUpViewModel.vb index ed7521f..9ec29f5 100644 --- a/SetUpWindow/SetUpViewModel.vb +++ b/SetUpWindow/SetUpViewModel.vb @@ -573,6 +573,14 @@ Namespace EgtCAM5 ' Direttorio per attrezzaggi Dim sDir As String = IniFile.m_sMachinesRoot & "\" & IniFile.m_sMachineName & "\SetUp" Dim sPath As String = String.Empty + If Not Directory.Exists(sDir) Then + Try + Directory.CreateDirectory(sDir) + Catch ex As Exception + EgtOutLog("Error in SetupDir creation " & ex.ToString()) + Return + End Try + End If ' Apertura dialogo di salvataggio Dim SaveFileDialogView As New EgtWPFLib5.EgtSaveFileDialog SaveFileDialogView.Title = EgtMsg(MSG_SETUP + 3) & " " & EgtMsg(MSG_SETUP + 1) @@ -634,6 +642,10 @@ Namespace EgtCAM5 ' Direttorio per attrezzaggi Dim sDir As String = IniFile.m_sMachinesRoot & "\" & IniFile.m_sMachineName & "\SetUp" Dim sPath As String = String.Empty + If Not Directory.Exists(sDir) Then + EgtOutLog("Error in SetupDir retrieve : directory not found") + Return + End If ' Apertura dialogo di salvataggio Dim OpenFileDialogView As New EgtWPFLib5.EgtOpenFileDialog OpenFileDialogView.Title = EgtMsg(MSG_SETUP + 4) & " " & EgtMsg(MSG_SETUP + 1)