Index: APPS/CRM/KlantService.cls.xml =================================================================== diff -u -r40096 -r74133 --- APPS/CRM/KlantService.cls.xml (.../KlantService.cls.xml) (revision 40096) +++ APPS/CRM/KlantService.cls.xml (.../KlantService.cls.xml) (revision 74133) @@ -156,7 +156,11 @@ Do dtoKlantBestand.Klanten.Insert(KlantIt.Next()) } + #dim Bestandsnaam As %String Set Bestandsnaam = ##class(TECH.Config.ConfigMgr).Instance().GetString("APPS.CRM.KlantService.KlantBestand") + If $$$Not(##class(TECH.File.impl.DirectoryUtils).%New().DirectoryExists(##class(TECH.File).GetDirectory(Bestandsnaam))) { + Do ##class(TECH.Exceptions.GeneralErrorException).Throw("Fout bij CRM.KlantService. Directory '"_Bestandsnaam_"' bestaat niet.") + } Do ..SchrijfKlantDto(Bestandsnaam, dtoKlantBestand) @@ -176,6 +180,10 @@ Set ConfigMgr = ##class(TECH.Config.ConfigMgr).Instance() Set Bestandsnaam = ConfigMgr.GetString("APPS.CRM.KlantService.KlantBestandIncrementeel") + If $$$Not(##class(TECH.File.impl.DirectoryUtils).%New().DirectoryExists(##class(TECH.File).GetDirectory(Bestandsnaam))) { + Do ##class(TECH.Exceptions.GeneralErrorException).Throw("Fout bij CRM.KlantService. Directory '"_Bestandsnaam_"' bestaat niet.") + } + Set Datum = ""_$zd($h,3) set Bestandsnaam = $$Replace^vhLib.String(Bestandsnaam,"::datum::",Datum) } Index: APPS/LEV/LeverancierService.cls.xml =================================================================== diff -u -r29059 -r74133 --- APPS/LEV/LeverancierService.cls.xml (.../LeverancierService.cls.xml) (revision 29059) +++ APPS/LEV/LeverancierService.cls.xml (.../LeverancierService.cls.xml) (revision 74133) @@ -53,7 +53,12 @@ Do dtoLeverancierBestand.Leveranciers.Insert(LeverancierIt.Next()) } + #dim Bestandsnaam As %String Set Bestandsnaam = ##class(TECH.Config.ConfigMgr).Instance().GetString("APPS.LEV.LeverancierService.LeverancierBestand") + + If $$$Not(##class(TECH.File.impl.DirectoryUtils).%New().DirectoryExists(##class(TECH.File).GetDirectory(Bestandsnaam))) { + Do ##class(TECH.Exceptions.GeneralErrorException).Throw("Fout bij LEV.LeverancierService. Directory '"_Bestandsnaam_"' bestaat niet.") + } Do ..SchrijfLeverancierDto(Bestandsnaam,dtoLeverancierBestand) @@ -73,6 +78,11 @@ if '$length(Bestandsnaam) { Set Bestandsnaam = ##class(TECH.Config.ConfigMgr).Instance().GetString("APPS.LEV.LeverancierService.LeverancierBestandIncrementeel") + + If $$$Not(##class(TECH.File.impl.DirectoryUtils).%New().DirectoryExists(##class(TECH.File).GetDirectory(Bestandsnaam))) { + Do ##class(TECH.Exceptions.GeneralErrorException).Throw("Fout bij LEV.LeverancierService. Directory '"_Bestandsnaam_"' bestaat niet.") + } + Set Datum = ""_$zd($h,3) set Bestandsnaam = $$Replace^vhLib.String(Bestandsnaam,"::datum::",Datum) }