From 0aca7e56cc1d352fa35f5004a0f52cb58d2ac3ca Mon Sep 17 00:00:00 2001 From: Dario Sassi Date: Mon, 15 Feb 2016 18:39:22 +0000 Subject: [PATCH] OmagCUT : - piccola miglioria nella gestione nomi progetto. --- CurrentProjectPageUC.xaml.vb | 14 +++++++++++++- 1 file changed, 13 insertions(+), 1 deletion(-) diff --git a/CurrentProjectPageUC.xaml.vb b/CurrentProjectPageUC.xaml.vb index ddbb34f..e6e88e5 100644 --- a/CurrentProjectPageUC.xaml.vb +++ b/CurrentProjectPageUC.xaml.vb @@ -321,6 +321,19 @@ Public Class CurrentProjectPageUC End If ' Notifico a foto il cambio di path EgtChangePhotoPath(nPhotoId, sNewPhoto) + ' Altrimenti cancello eventuali file di foto associabili al progetto + Else + Dim sPhoto1 As String = Path.ChangeExtension(sPath, "jpg") + Dim sPhoto2 As String = Path.ChangeExtension(sPath, "png") + Try + If My.Computer.FileSystem.FileExists(sPhoto1) Then + My.Computer.FileSystem.DeleteFile(sPhoto1) + End If + If My.Computer.FileSystem.FileExists(sPhoto2) Then + My.Computer.FileSystem.DeleteFile(sPhoto2) + End If + Catch ex As Exception + End Try End If ' Se assente, inserisco contrassegno di progetto OmagCut valido AddProjectMark() @@ -382,7 +395,6 @@ Public Class CurrentProjectPageUC Return True End Function - Friend Function RemovePreviewFromParts() As Boolean ' Processo i sottogruppi, se di livello System li rimuovo Dim nGrpId As Integer = EgtGetFirstGroupInGroup(GDB_ID.ROOT)