fix export to folder

This commit is contained in:
Jonathan Jenne 2024-01-05 10:49:12 +01:00
parent 1abfb8dc31
commit 5055a19959
2 changed files with 9 additions and 3 deletions

View File

@ -222,7 +222,7 @@ Public Class ClassParamRefresh
ElseIf oMode.StartsWith("PM.ButtonExport2FolderCaption") Then ElseIf oMode.StartsWith("PM.ButtonExport2FolderCaption") Then
Dim oAfterReplace = oMode.Replace("PM.ButtonExport2FolderCaption=", "") Dim oAfterReplace = oMode.Replace("PM.ButtonExport2FolderCaption=", "")
ButtonExport2Folder_Caption = oAfterReplace ButtonExport2Folder_Caption = oAfterReplace
ElseIf oMode.StartsWith("PM.ButtonExportMode") Then ElseIf oMode.StartsWith("PM.ButtonExport2Folder_Mode") Then
Dim oAfterReplace = oMode.Replace("PM.ButtonExport2Folder_Mode=", "") Dim oAfterReplace = oMode.Replace("PM.ButtonExport2Folder_Mode=", "")
ButtonExport2Folder_Mode = oAfterReplace ButtonExport2Folder_Mode = oAfterReplace
ElseIf oMode.StartsWith("PM.ButtonExport2Folder_RootFolder") Then ElseIf oMode.StartsWith("PM.ButtonExport2Folder_RootFolder") Then

View File

@ -5657,14 +5657,20 @@ Public Class frmValidator
Dim oConverter As New PDFConverter(LOGCONFIG) Dim oConverter As New PDFConverter(LOGCONFIG)
If oConverter.ConvertPDFADocumentToPDFDocument(WMDocPathWindows, oTempFullFilename) = False Then If oConverter.ConvertPDFADocumentToPDFDocument(WMDocPathWindows, oTempFullFilename) = False Then
Logger.Warn("File [{0}] could not be converted to plain PDF!", WMDocPathWindows) Logger.Warn("File [{0}] could not be converted to plain PDF!", WMDocPathWindows)
oFile2Export = WMDocPathWindows
Else
oFile2Export = oTempPath
End If End If
Else
oFile2Export = oTempPath oFile2Export = WMDocPathWindows
End If End If
Else
oFile2Export = WMDocPathWindows
End If End If
Else Else
oFile2Export = WMDocPathWindows oFile2Export = WMDocPathWindows
End If End If
Logger.Info("Final export path is: [{0}]", oFile2Export)
File.Copy(oFile2Export, oTargetPath) File.Copy(oFile2Export, oTargetPath)
Logger.Info($"File {WMDocPathWindows} exported successfully!") Logger.Info($"File {WMDocPathWindows} exported successfully!")
oCount += 1 oCount += 1