Datev-Anbindung

This commit is contained in:
2023-05-08 14:21:21 +02:00
parent 9ed0834f71
commit 887c64c2d1
3 changed files with 130 additions and 109 deletions

View File

@@ -3533,12 +3533,19 @@ Nächste_Textzeile_lesen:
' Case Else
' whereKTO = " AND AKTO IN ('006136','006128','3517233') "
'End Select
Try
Dim dt As DataTable = SQL.loadDgvBySql("SELECT [Index] FROM [Zkteing] where Bezugsnummer='" & SPEDBUCH.AtlasBezNrEZA & "' AND LeistungsNr IN (20,77) AND [Status] IS NULL " & whereKTO, "FMZOLL")
For Each r In dt.Rows
VERAG_PROG_ALLGEMEIN.cZkteing.UPDATE_Status("X", r("Index"))
przInsertEUSTZOLL(r("Index"))
Next
Catch ex As Exception
MsgBox(ex.Message)
End Try
Dim dt As DataTable = SQL.loadDgvBySql("SELECT [Index] FROM [Zkteing] where Bezugsnummer='" & SPEDBUCH.AtlasBezNrEZA & "' AND LeistungsNr IN (20,77) AND [Status] IS NULL " & whereKTO, "FMZOLL")
For Each r In dt.Rows
VERAG_PROG_ALLGEMEIN.cZkteing.UPDATE_Status("X", r("Index"))
przInsertEUSTZOLL(r("Index"))
Next
End Sub
'Case 20, 77
'Case 10, 76, 60
@@ -3556,12 +3563,17 @@ Nächste_Textzeile_lesen:
' Case Else
' whereKTO = " AND AKTO IN ('006136','006128','3517233') "
'End Select
Try
Dim dt As DataTable = SQL.loadDgvBySql("SELECT [Index] FROM [Zkteing] where Bezugsnummer='" & SPEDBUCH.AtlasBezNrEZA & "' AND LeistungsNr NOT IN (20,77) AND [Status] IS NULL " & whereKTO, "FMZOLL")
For Each r In dt.Rows
VERAG_PROG_ALLGEMEIN.cZkteing.UPDATE_Status("X", r("Index"))
przInsertEUSTZOLL(r("Index"))
Next
Catch ex As Exception
MsgBox(ex.Message)
End Try
Dim dt As DataTable = SQL.loadDgvBySql("SELECT [Index] FROM [Zkteing] where Bezugsnummer='" & SPEDBUCH.AtlasBezNrEZA & "' AND LeistungsNr NOT IN (20,77) AND [Status] IS NULL " & whereKTO, "FMZOLL")
For Each r In dt.Rows
VERAG_PROG_ALLGEMEIN.cZkteing.UPDATE_Status("X", r("Index"))
przInsertEUSTZOLL(r("Index"))
Next
End Sub
Sub loadBerechnungsArt_jeAbfertigung()
If Not IsNumeric(SPEDBUCH.Abfertigungsanzahl) Then Exit Sub

View File

@@ -1463,8 +1463,12 @@ Public Class usrcntlKundeBearbeitenFull
End Sub
Private Sub btnDatevExport_Click(sender As Object, e As EventArgs) Handles btnDatevExport.Click
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("DATEV_EXPORT", "SDL") Then
VERAG_PROG_ALLGEMEIN.cDatev_Interface.genDatensatzCSV_ALL(False, True, False)
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("DATEV_EXPORT", "SDL") And VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA = "AMBAR" Then
If VERAG_PROG_ALLGEMEIN.cDatev_Interface.genDatensatzCSV_ALL(VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA, False, True, False) Then
MsgBox("Stammdaten wurden erfolgreich exportiert!")
Else
MsgBox("Es wurden keine Stammdaten exportiert!")
End If
End If
End Sub