Fiskalkunden-Fertigstellung

This commit is contained in:
2023-06-13 13:44:44 +02:00
parent cd0e9a21f6
commit d7db9c50c9
7 changed files with 597 additions and 397 deletions

View File

@@ -1300,7 +1300,6 @@ Public Class cFormularManager
End Function
Public Shared Sub PrintViaGS(PDFFile As String, printerName As String)
Try
Dim assembly = System.Reflection.Assembly.GetExecutingAssembly()
@@ -1938,6 +1937,31 @@ Public Class DATENVERVER_OPTIONS
End Function
Public Shared Function getPDFViaSpirePDF_FromFile(File As String, Optional targetPath As String = "") As String
Try
If targetPath = "" Then targetPath = TMP_PATH
VERAG_PROG_ALLGEMEIN.cProgramFunctions.spireLoadLicense()
Dim doc As New Spire.Pdf.PdfDocument '= New Spire.Pdf.PdfDocument(URL)
doc.LoadFromHTML(File, False, False, False)
'doc.LoadFromFile(File)
If doc IsNot Nothing Then
doc.PageSettings.Size = Spire.Pdf.PdfPageSize.A4
doc.PrintDocument.DefaultPageSettings.Landscape = True
doc.PageScaling = Spire.Pdf.PdfPrintPageScaling.FitSize
' doc.PrinterName = printerName
' doc.PrintDocument.Print()
doc.SaveToFile(targetPath)
End If
Return targetPath
Catch ex As Exception
MsgBox(ex.Message & ex.StackTrace)
End Try
Return ""
End Function
End Class
Public Class barcodeToPdf