Merge branch 'newMaster2024' of https://dev.azure.com/VeragAG/_git/SDL into newMaster2024

This commit is contained in:
2025-04-22 15:24:34 +02:00
109 changed files with 9220 additions and 3143 deletions

View File

@@ -880,6 +880,7 @@ Public Class SQL
conn.Close()
Return True
Catch ex As Exception
' MsgBox("ERR!")
If showErr Then VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name, , , , , sql)
End Try
Return False

View File

@@ -293,7 +293,7 @@ Public Class cUStVPositionen
Property UStVPo_ReNr As Object = Nothing ' NVARCHAR(20) NULL,
Property UStVPo_USteuerbetrag As Object = Nothing ' MONEY Not NULL,
Property UStVPo_Leistungsbezeichnung As Object = Nothing ' NVARCHAR(255) NULL,
Property UStVPo_Leistender As Object = Nothing ' NVARCHAR(65) NULL,
Property UStVPo_Leistender As String = "" ''NVARCHAR(65) NULL,
Property UStVPo_Schnittstelle As Object = Nothing ' BIT Default ((0)) Not NULL,
Property UStVPo_SchnittstellenNr As Object = Nothing ' SMALLINT Default ((0)) Not NULL,
Property UStVPo_Umrechnungskurs As Object = Nothing ' FLOAT(53) NULL,
@@ -301,7 +301,8 @@ Public Class cUStVPositionen
Property UStVPo_Sachbearbeiter As Object = Nothing ' NVARCHAR(15) NULL,
Property UStVPo_Zeitstempel As Object = Nothing ' DATETIME Default (getdate()) NULL,
Property UStVPo_daId As Object = Nothing
Property UStVPo_daId_loeschbar As Object = Nothing
Property UStVPo_daId_loeschbar As Boolean = True
Property UStVPo_LeistenderId As Integer '
Dim SQL As New SQL
@@ -363,6 +364,20 @@ Public Class cUStVPositionen
End Function
Public Function SAVEID() As Integer
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
Dim ustava_posId = -1
Dim sqlstr = " BEGIN TRAN IF EXISTS(SELECT * FROM tblUStVPositionen WHERE UStVAn_ID=@UStVAn_ID AND UStVPo_ID=@UStVPo_ID) " &
" BEGIN " & getUpdateCmd() & " END " &
" Else " &
" BEGIN " & getInsertCmd() & " END " &
" commit tran "
ustava_posId = SQL.doSQLVarListID(ustava_posId, sqlstr, "FMZOLL", , list)
Return ustava_posId
End Function
Public Function getUpdateCmd() As String
Try
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
@@ -401,6 +416,7 @@ Public Class cUStVPositionen
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVPo_Zeitstempel", UStVPo_Zeitstempel))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVPo_daId", UStVPo_daId))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVPo_daId_loeschbar", UStVPo_daId_loeschbar))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVPo_LeistenderId", UStVPo_LeistenderId))
Return list
End Function

View File

@@ -11,17 +11,27 @@ Public Class cUStVLeistender
Property UstV_Leistender_Land As Object = Nothing
Property UstV_Leistender_UstNr As Object = Nothing
Property UstV_Leistender_Adresse As Boolean
Property UStV_LeistenderId As Integer
Public hasEntry = False
Dim SQL As New SQL
Sub New(UStV_Leistender)
Sub New(UStV_Leistender As String)
Me.UStV_Leistender = UStV_Leistender
LOAD()
End Sub
Sub New(Id As Integer)
Me.UStV_LeistenderId = Id
LOADBYID()
End Sub
Sub New(UStV_Leistender As String, Land As String)
Me.UStV_Leistender = UStV_Leistender
LOADByLand(Land)
End Sub
Function getParameterList() As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable)
Dim list As New List(Of VERAG_PROG_ALLGEMEIN.SQLVariable)
@@ -33,6 +43,7 @@ Public Class cUStVLeistender
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UstV_Leistender_Land", UstV_Leistender_Land))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UstV_Leistender_UstNr", UstV_Leistender_UstNr))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UstV_Leistender_Adresse", UstV_Leistender_Adresse))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStV_LeistenderId", UStV_LeistenderId,, True))
Return list
End Function
@@ -47,10 +58,29 @@ Public Class cUStVLeistender
" BEGIN " & getInsertCmd() & " END " &
" commit tran "
Return SQL.doSQLVarList(sqlstr, "FMZOLL", , list)
End Function
Public Function SAVEID() As Integer
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
Dim sqlstr = " BEGIN TRAN IF EXISTS(SELECT * FROM tblUStVLeistender WHERE UStV_Leistender=@UStV_Leistender) " &
" BEGIN " & getUpdateCmd() & " END " &
" Else " &
" BEGIN " & getInsertCmd() & " END " &
" commit tran "
UStV_LeistenderId = SQL.doSQLVarListID(UStV_LeistenderId, sqlstr, "FMZOLL", , list)
Return UStV_LeistenderId
End Function
Public Function INSERT() As Boolean
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
@@ -60,9 +90,9 @@ Public Class cUStVLeistender
End Function
Public Sub LOAD()
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT * FROM tblUStVLeistender WHERE UStV_Leistender=@UStV_Leistender ", conn)
cmd.Parameters.AddWithValue("@UStV_Leistender", UStV_Leistender)
Dim dr = cmd.ExecuteReader()
@@ -82,14 +112,73 @@ Public Class cUStVLeistender
dr.Close()
End Using
End Using
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
End Sub
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
End Sub
Public Function getUpdateCmd() As String
Public Sub LOADBYID()
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT * FROM tblUStVLeistender WHERE UStV_LeistenderId=@UStV_LeistenderId ", conn)
cmd.Parameters.AddWithValue("@UStV_LeistenderId", UStV_LeistenderId)
Dim dr = cmd.ExecuteReader()
If dr.Read Then
For Each li In getParameterList()
Dim propInfo As PropertyInfo = Me.GetType.GetProperty(li.Scalarvariable)
If dr.Item(li.Text) Is DBNull.Value Then
propInfo.SetValue(Me, Nothing)
Else
propInfo.SetValue(Me, dr.Item(li.Text))
End If
Next
hasEntry = True
End If
dr.Close()
End Using
End Using
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
End Sub
Public Sub LOADByLand(Land As String)
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT * FROM tblUStVLeistender WHERE UStV_Leistender=@UStV_Leistender and left(UstV_Leistender_UstNr, 2) = '" & Land & "'", conn)
cmd.Parameters.AddWithValue("@UStV_Leistender", UStV_Leistender)
Dim dr = cmd.ExecuteReader()
If dr.Read Then
For Each li In getParameterList()
Dim propInfo As PropertyInfo = Me.GetType.GetProperty(li.Scalarvariable)
If dr.Item(li.Text) Is DBNull.Value Then
propInfo.SetValue(Me, Nothing)
Else
propInfo.SetValue(Me, dr.Item(li.Text))
End If
Next
hasEntry = True
End If
dr.Close()
End Using
End Using
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
End Sub
Public Function getUpdateCmd() As String
Try
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()

View File

@@ -26,6 +26,7 @@ Public Enum cAPI_ART
AVISO_IN_MSE = 80
SDL_OUT_FA = 81
SDL_OUT_SAMMELRECHNUNG = 82
End Enum

View File

@@ -12,6 +12,7 @@ Public Class cGrenzstelle
Property grz_Cluster As Object = Nothing
Property grz_Reihenfolge As Integer
Property grz_Warenort As Boolean
Property grz_AvisoStatusVorOrt As Boolean
Property grz_Zollamt As Boolean
Property grz_Aktiv As Boolean
Property grz_ZollamtDST As Object = Nothing
@@ -45,6 +46,7 @@ Public Class cGrenzstelle
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grz_Aktiv", grz_Aktiv))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grz_ZollamtDST", grz_ZollamtDST))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grz_ZollamtBezeichnung", grz_ZollamtBezeichnung))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grz_AvisoStatusVorOrt", grz_AvisoStatusVorOrt))
Return list
End Function

View File

@@ -0,0 +1,137 @@

Imports System.Data.SqlClient
Imports System.Reflection
Public Class cGruppeKundenNr
Property grp_Gruppe As String
Property grp_KdNr As Integer
Property grp_isStamm As Boolean = False
Property grp_StammKdNr As Integer
Property grp_Firma As String
Public hasEntry = False
Dim SQL As New SQL
Sub New(grp_Gruppe, grp_KdNr)
Me.grp_Gruppe = grp_Gruppe
Me.grp_KdNr = grp_KdNr
LOAD()
End Sub
Function getParameterList() As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable)
Dim list As New List(Of VERAG_PROG_ALLGEMEIN.SQLVariable)
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grp_Gruppe", grp_Gruppe))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grp_KdNr", grp_KdNr))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grp_isStamm", grp_isStamm))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grp_StammKdNr", grp_StammKdNr))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("grp_Firma", grp_Firma))
Return list
End Function
Public Function SAVE() As Boolean
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
Dim sqlstr = " BEGIN TRAN IF EXISTS(SELECT * FROM tblGruppeKundenNr WHERE grp_Gruppe=@grp_Gruppe AND grp_KdNr=@grp_KdNr) " &
" BEGIN " & getUpdateCmd() & " END " &
" Else " &
" BEGIN " & getInsertCmd() & " END " &
" commit tran "
Return SQL.doSQLVarList(sqlstr, "FMZOLL", , list)
End Function
Public Function DELETE() As Boolean
Dim sqlstr = " DELETE [tblGruppeKundenNr] WHERE grp_Gruppe='" & grp_Gruppe & "' AND grp_KdNr='" & grp_KdNr & "' "
Return SQL.doSQL(sqlstr, "FMZOLL")
End Function
Public Sub LOAD()
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT * FROM tblGruppeKundenNr WHERE grp_Gruppe=@grp_Gruppe AND grp_KdNr=@grp_KdNr ", conn)
cmd.Parameters.AddWithValue("@grp_Gruppe", grp_Gruppe)
cmd.Parameters.AddWithValue("@grp_KdNr", grp_KdNr)
Dim dr = cmd.ExecuteReader()
If dr.Read Then
For Each li In getParameterList()
Dim propInfo As PropertyInfo = Me.GetType.GetProperty(li.Scalarvariable)
If dr.Item(li.Text) Is DBNull.Value Then
propInfo.SetValue(Me, Nothing)
Else
propInfo.SetValue(Me, dr.Item(li.Text))
End If
Next
hasEntry = True
End If
dr.Close()
End Using
End Using
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
End Sub
Public Function getUpdateCmd() As String
Try
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
Dim str As String = ""
For Each i In list
If Not i.isPrimaryParam Then
str &= "[" & i.Text & "] = @" & i.Scalarvariable & "," '.Replace("-", "").Replace(" ", "") & ","
End If
Next
str = str.Substring(0, str.Length - 1) 'wg. ','
Return (" UPDATE [tblGruppeKundenNr] SET " & str & " WHERE grp_Gruppe=@grp_Gruppe AND grp_KdNr=@grp_KdNr ")
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
Return ""
End Function
Shared Function checkStamm(StammKdNr) As Boolean
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
Return (SQL.getValueTxtBySql("SELECT count(*) FROM [tblGruppeKundenNr] where grp_kdNr=" & StammKdNr & " and grp_isStamm=1 ", "FMZOLL",,, 0) > 0)
End Function
Shared Function cntGroupStamm(StammKdNr) As Boolean
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
Return (SQL.getValueTxtBySql("SELECT count(*) FROM [tblGruppeKundenNr] where grp_kdNr=" & StammKdNr & " and grp_isStamm=1 ", "FMZOLL",,, 0))
End Function
Shared Function getStamm(KdNr) As Integer
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
Return SQL.getValueTxtBySql("SELECT grp_StammKdNr FROM [tblGruppeKundenNr] where grp_kdNr=" & KdNr & " ", "FMZOLL",,, -1)
End Function
Public Function getInsertCmd() As String
Try
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
Dim str As String = ""
Dim values As String = ""
For Each i In list
If Not i.isPrimaryParam Then
str &= "[" & i.Text & "],"
values &= "@" & i.Scalarvariable & "," '.Replace("-", "").Replace(" ", "") & ","
End If
Next
str = str.Substring(0, str.Length - 1) 'wg. ','
values = values.Substring(0, values.Length - 1) 'wg. ','
Return (" INSERT INTO tblGruppeKundenNr (" & str & ") VALUES(" & values & ") ")
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
Return ""
End Function
End Class

View File

@@ -247,34 +247,45 @@ Public Class cIDS
Else
Try
Dim ymd = isleernothing((currentRow(0)))
Dim cc = isleernothing((currentRow(1)))
Dim pyn = isleernothing((currentRow(2)))
Dim occ = isleernothing((currentRow(5)))
Dim oc = isleernothing((currentRow(6)))
Dim ptc = isleernothing((currentRow(7)))
Dim ids As New cIDS(ymd, pyn, cc, occ, oc, ptc)
Dim ymd = isleernothing((currentRow(0)))
Dim cc = isleernothing((currentRow(1)))
Dim pyn = isleernothing((currentRow(2)))
Dim occ = isleernothing((currentRow(5)))
Dim oc = isleernothing((currentRow(6)))
Dim ptc = isleernothing((currentRow(7)))
Dim ids As New cIDS(ymd, pyn, cc, occ, oc, ptc)
Dim avprive = isleernothing((currentRow(12)))
With ids
.YearMonthDay = isleernothing((currentRow(0)))
.CustomerCode = isleernothing((currentRow(1)))
.Paymentsummarynumber = isleernothing((currentRow(2)))
.CustomerName = isleernothing((currentRow(3)))
.OutletCountry = isleernothing((currentRow(4)))
.OutletCountryCode = isleernothing((currentRow(5)))
.OutletCode = isleernothing((currentRow(6)))
.ProductTypeCode = isleernothing((currentRow(7)))
.TransactionVolume = isleernothing((currentRow(8)))
.AmminclVAT = isleernothing((currentRow(9)))
.TotalNetAmount = isleernothing((currentRow(10)))
.VATAmount = isleernothing((currentRow(11)))
.avpriceexclVAT = IIf(avprive <> "" AndAlso IsNumeric(avprive), avprive, 0)
.VRNumber = isleernothing((currentRow(13)))
.OBONumber = isleernothing((currentRow(14)))
Console.WriteLine("IDS: " & isleernothing((currentRow(1))) & " - " & lngRecordCount & " - " & isleernothing((currentRow(10))))
.SAVE()
End With
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
With ids
.YearMonthDay = isleernothing((currentRow(0)))
.CustomerCode = isleernothing((currentRow(1)))
.Paymentsummarynumber = isleernothing((currentRow(2)))
.CustomerName = isleernothing((currentRow(3)))
.OutletCountry = isleernothing((currentRow(4)))
.OutletCountryCode = isleernothing((currentRow(5)))
.OutletCode = isleernothing((currentRow(6)))
.ProductTypeCode = isleernothing((currentRow(7)))
.TransactionVolume = isleernothing((currentRow(8)))
.AmminclVAT = isleernothing((currentRow(9)))
.TotalNetAmount = isleernothing((currentRow(10)))
.VATAmount = isleernothing((currentRow(11)))
.avpriceexclVAT = isleernothing((currentRow(12)))
.VRNumber = isleernothing((currentRow(13)))
.OBONumber = isleernothing((currentRow(14)))
.SAVE()
End With
End If
Loop

View File

@@ -1,8 +1,9 @@
Imports javax.validation.constraints

Public Class cMDMFunctionsAllgemein
Public Shared ploseSchnittstelle As Boolean = False
Public Shared ploseAlteLogikSchnittstelle As Boolean = False
Public Shared ploseNeueLogikSchnittstelle As Boolean = False
Public Shared ITSchnittstelle As Boolean = False
Public Shared MSEAlteSchnittstelle As Boolean = False
Public Shared MSENeueSchnittstelle As Boolean = False
@@ -11,9 +12,10 @@ Public Class cMDMFunctionsAllgemein
Public Shared UTAAlteSchnittstelle As Boolean = False
Public Shared UTANeueSchnittstelle As Boolean = False
Shared Function setSchnittstellen(plose As Boolean, IT As Boolean, MSEalt As Boolean, MSENeu As Boolean, IDSAlt As Boolean, IDSNeu As Boolean, UTAAlt As Boolean, UTANeu As Boolean)
Shared Function setSchnittstellen(ploseAlt As Boolean, IT As Boolean, MSEalt As Boolean, MSENeu As Boolean, IDSAlt As Boolean, IDSNeu As Boolean, UTAAlt As Boolean, UTANeu As Boolean, ploseNeu As Boolean)
ploseSchnittstelle = plose
ploseAlteLogikSchnittstelle = ploseAlt
ploseNeueLogikSchnittstelle = ploseNeu
ITSchnittstelle = IT
MSEAlteSchnittstelle = MSEalt
MSENeueSchnittstelle = MSENeu
@@ -22,6 +24,20 @@ Public Class cMDMFunctionsAllgemein
UTAAlteSchnittstelle = UTAAlt
UTANeueSchnittstelle = UTANeu
If VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM Then
ploseAlteLogikSchnittstelle = True
ploseNeueLogikSchnittstelle = True
ITSchnittstelle = False
MSEAlteSchnittstelle = True
MSENeueSchnittstelle = True
IDSAlteSchnittstelle = True
IDSNeueSchnittstelle = True
UTAAlteSchnittstelle = True
UTANeueSchnittstelle = True
End If
End Function
@@ -127,8 +143,9 @@ Public Class cMDMFunctionsAllgemein
End If
'alle Kunden, die eine SteuerNr hinterlegt haben inkl. deren hinterlegte Summen!
Dim sqlKunden = "SELECT Kunden.KundenNr as KundenNr, Kunden.UStV_SummeUmsatzsteuerbetragEUR, Kunden.UStV_SummeErstattungsbetragEUR, Kunden.UStV_Summe3470BetragEUR, Kunden.UStV_SummeVZBetragEUR, Kunden.UStV_SummeVorschaubetragEUR_VERAG, Kunden.UStV_SummeVorschaubetragEUR_IDS, Kunden.UStV_SummeVorschaubetragEUR_IT, Kunden.UStV_SummeVorschaubetragEUR_MSE, Kunden.UStV_SummeVorschaubetragEUR_UTA, Kunden.UStV_SummeVorschaubetragEUR, kde_UStV_SummeVorschaubetragEUR_PLOSE as UStV_SummeVorschaubetragEUR_PLOSE
Dim sqlKunden = "SELECT Kunden.KundenNr as KundenNr,isnull(Adressen.LandKz,'') as LandKz, Kunden.UStV_SummeUmsatzsteuerbetragEUR, Kunden.UStV_SummeErstattungsbetragEUR, Kunden.UStV_Summe3470BetragEUR, Kunden.UStV_SummeVZBetragEUR, Kunden.UStV_SummeVorschaubetragEUR_VERAG, Kunden.UStV_SummeVorschaubetragEUR_IDS, Kunden.UStV_SummeVorschaubetragEUR_IT, Kunden.UStV_SummeVorschaubetragEUR_MSE, Kunden.UStV_SummeVorschaubetragEUR_UTA, Kunden.UStV_SummeVorschaubetragEUR, kde_UStV_SummeVorschaubetragEUR_PLOSE as UStV_SummeVorschaubetragEUR_PLOSE
FROM Kunden
INNER JOIN Adressen on Adressen.AdressenNr = Kunden.KundenNr
left JOIN [tblKundenErweitert] on [kde_KundenNr] = Kunden.KundenNr
WHERE Kunden.KundenNr " & sqlWhere &
" order by Kunden.KundenNr"
@@ -143,6 +160,13 @@ Public Class cMDMFunctionsAllgemein
'Neuberechnung der Steuerbeträge aus den Anträgen
'WICHTIG laut Brigitte am 09.04.2025:
'SRB und BIH Kunden bekommen die MWST direkt vom HU Finanzamt ausbezahlt.
'Deswegen sollten alle ungarischen Anträge die wir für SRB und BIH Kunden stellen, nicht beim Risiko mitberechnet werden
Dim sqlSummeBilden = "SELECT
tblUStVAntrag.UStVAn_KuNr,
SUM(tblUStVAntrag.UStVAn_USteuerbetragEUR) As UStVKu_SummeUmsatzsteuer,
@@ -176,13 +200,12 @@ Public Class cMDMFunctionsAllgemein
Dim invoiceDate = If(Date.Now > New Date(Date.Now.Year, 6, 30), New Date(Date.Now.Year, 1, 1), New Date(Date.Now.Year - 1, 1, 1))
'Neuberechnung der Vorschausummen (also alle noch nicht verrechneten Transaktionen , die aber schon eingelesen wurden)
curUStV_SummeVorschaubetragEUR_VERAG = UStVKunden_Summen_lesen_Vorschau_VERAG(r.Item("KundenNr"), invoiceDate)
curUStV_SummeVorschaubetragEUR_IDS = UStVKunden_Summen_lesen_Vorschau_IDS(r.Item("KundenNr"), invoiceDate, IDSAlteSchnittstelle, IDSNeueSchnittstelle)
curUStV_SummeVorschaubetragEUR_IT = UStVKunden_Summen_lesen_Vorschau_IT(r.Item("KundenNr"), invoiceDate, ITSchnittstelle)
curUStV_SummeVorschaubetragEUR_MSE = UStVKunden_Summen_lesen_Vorschau_MSE(r.Item("KundenNr"), invoiceDate, MSEAlteSchnittstelle, MSENeueSchnittstelle)
curUStV_SummeVorschaubetragEUR_UTA = UStVKunden_Summen_lesen_Vorschau_UTA(r.Item("KundenNr"), invoiceDate, UTAAlteSchnittstelle, UTANeueSchnittstelle)
curUStV_SummeVorschaubetragEUR_PLOSE = UStVKunden_Summen_lesen_Vorschau_PLOSE(r.Item("KundenNr"), invoiceDate, ploseSchnittstelle)
curUStV_SummeVorschaubetragEUR_VERAG = UStVKunden_Summen_lesen_Vorschau_VERAG(r.Item("KundenNr"), r.Item("LandKz"), invoiceDate)
curUStV_SummeVorschaubetragEUR_IDS = UStVKunden_Summen_lesen_Vorschau_IDS(r.Item("KundenNr"), r.Item("LandKz"), invoiceDate, IDSAlteSchnittstelle, IDSNeueSchnittstelle)
curUStV_SummeVorschaubetragEUR_IT = UStVKunden_Summen_lesen_Vorschau_IT(r.Item("KundenNr"), r.Item("LandKz"), invoiceDate, ITSchnittstelle)
curUStV_SummeVorschaubetragEUR_MSE = UStVKunden_Summen_lesen_Vorschau_MSE(r.Item("KundenNr"), r.Item("LandKz"), invoiceDate, MSEAlteSchnittstelle, MSENeueSchnittstelle)
curUStV_SummeVorschaubetragEUR_UTA = UStVKunden_Summen_lesen_Vorschau_UTA(r.Item("KundenNr"), r.Item("LandKz"), invoiceDate, UTAAlteSchnittstelle, UTANeueSchnittstelle)
curUStV_SummeVorschaubetragEUR_PLOSE = UStVKunden_Summen_lesen_Vorschau_PLOSE(r.Item("KundenNr"), r.Item("LandKz"), invoiceDate, ploseAlteLogikSchnittstelle, ploseNeueLogikSchnittstelle)
curUStV_SummeVorschaubetragEUR += curUStV_SummeVorschaubetragEUR_VERAG
curUStV_SummeVorschaubetragEUR += curUStV_SummeVorschaubetragEUR_IDS
@@ -301,7 +324,7 @@ Public Class cMDMFunctionsAllgemein
End Try
End Function
Shared Function UStVKunden_Summen_lesen_Vorschau_VERAG(varUStVAn_KuNr As Integer, invoiceDate As Date) As Double
Shared Function UStVKunden_Summen_lesen_Vorschau_VERAG(varUStVAn_KuNr As Integer, landKZ As String, invoiceDate As Date) As Double
'Return 0
' Public Function UStVKunden_Summen_lesen_Vorschau_VERAG(ByRef varUStVAn_KuNr As Variant) As Currency
@@ -347,7 +370,7 @@ Public Class cMDMFunctionsAllgemein
End Function
Shared Function UStVKunden_Summen_lesen_Vorschau_IDS(varUStVAn_KuNr As Integer, invoiceDate As Date, calcSummeAlteSchnittstelle As Boolean, calcSummeNeueSchnittstelle As Boolean) As Double
Shared Function UStVKunden_Summen_lesen_Vorschau_IDS(varUStVAn_KuNr As Integer, landKZ As String, invoiceDate As Date, calcSummeAlteSchnittstelle As Boolean, calcSummeNeueSchnittstelle As Boolean) As Double
'1300 dtmRechnungsdatum = IIf(Date > DateSerial(Year(Date), 6, 30), DateSerial(Year(Date), 1, 1), DateSerial(Year(Date) - 1, 1, 1))
'1310 strParameter = ParameterBereitstellen(varUStVAn_KuNr, dtmRechnungsdatum)
@@ -373,7 +396,7 @@ Public Class cMDMFunctionsAllgemein
dbo.tblSteuernummern ON dbo.tblDieselArchiv.KdNrVERAG = dbo.tblSteuernummern.AdressenNr INNER JOIN
dbo.tbl_IDS_Länder ON dbo.tblSteuernummern.LandNr = dbo.tbl_IDS_Länder.LandNr AND dbo.tblDieselArchiv.[Outlet Country Code] = dbo.tbl_IDS_Länder.OutletCountryCode
WHERE (dbo.tblDieselArchiv.KdNrVERAG = " & varUStVAn_KuNr & " ) AND (dbo.tblDieselArchiv.[Year Month Day] >= '" & invoiceDate.ToShortDateString & "') AND (dbo.tblDieselArchiv.UStVAn_ID IS NULL) AND
(dbo.tblSteuernummern.UStV = 1)
(dbo.tblSteuernummern.UStV = 1) " & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
GROUP BY dbo.tblDieselArchiv.KdNrVERAG, dbo.tblSteuernummern.LandNr
ORDER BY dbo.tblDieselArchiv.KdNrVERAG, dbo.tblSteuernummern.LandNr"
@@ -395,14 +418,14 @@ Public Class cMDMFunctionsAllgemein
dbo.tblSteuernummern ON [tblIDSTransactionsNew].KdNrVERAG = dbo.tblSteuernummern.AdressenNr INNER JOIN
dbo.tbl_IDS_Länder ON dbo.tblSteuernummern.LandNr = dbo.tbl_IDS_Länder.LandNr AND [tblIDSTransactionsNew].[OutletCountryCode] = dbo.tbl_IDS_Länder.OutletCountryCode
WHERE ([tblIDSTransactionsNew].KdNrVERAG = " & varUStVAn_KuNr & " ) AND ([tblIDSTransactionsNew].[YearMonthDay] >= '" & invoiceDate.ToShortDateString & "') AND ([tblIDSTransactionsNew].UStVAn_ID IS NULL) AND
(dbo.tblSteuernummern.UStV = 1)
(dbo.tblSteuernummern.UStV = 1) " & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
GROUP BY [tblIDSTransactionsNew].KdNrVERAG, dbo.tblSteuernummern.LandNr
ORDER BY [tblIDSTransactionsNew].KdNrVERAG, dbo.tblSteuernummern.LandNr"
Dim dtIDSENeut As DataTable = sql.loadDgvBySql(sqlFMZollDatenNEU, "FMZOLL")
For Each r As DataRow In dtIDSENeut.Rows
Dim UST_org = CDbl(r.Item("UST_EUR"))
Dim UST_org = CDbl(r.Item("Vorschaubetrag"))
If UST_org <> 0 Then
summeNeueSchnittstelle += UST_org
End If
@@ -420,19 +443,25 @@ Public Class cMDMFunctionsAllgemein
End Function
Shared Function UStVKunden_Summen_lesen_Vorschau_PLOSE(varUStVAn_KuNr As Integer, invoiceDate As Date, calcSumme As Boolean) As Double
Shared Function UStVKunden_Summen_lesen_Vorschau_PLOSE(varUStVAn_KuNr As Integer, landKZ As String, invoiceDate As Date, calcSummeAlteSchnittstelle As Boolean, calcSummeNeueSchnitttelle As Boolean) As Double
' set plose_Archiv=1, [plose_ArchiviertDatum]=GETDATE(), UStVAn_ID = @UStVAn_ID beim Einarbeiten in USTVA
Try
Dim sql As New VERAG_PROG_ALLGEMEIN.SQL
Dim summeSchnittstelle As Double = 0
Dim summeAlteSchnittstelle As Double = 0
Dim summeNeueSchnittstelle As Double = 0
If calcSumme Then
If calcSummeAlteSchnittstelle Then
Dim sqlPLOSE = "select plose_POLSEKundennummer, sum([plose_MWSTBetragWaehrungAbbuchung])[plose_MWSTBetragWaehrungAbbuchung] FROM [tblPLOSE_Details] INNER JOIN Adressen on PLOSEKundenNr=plose_POLSEKundennummer
WHERE plose_Archiv <> 1 AND plose_Fakturiert = 1 AND plose_LieferantCode IN (0,1,7) AND cast(plose_RechnungsDatum as date) >= '" & invoiceDate.ToShortDateString & "' and AdressenNr = " & varUStVAn_KuNr & "
'plose_MWSTBetragWaehrungAbbuchung ist immer in EUR
Dim sqlPLOSE = "select plose_POLSEKundennummer, sum([plose_MWSTBetragWaehrungAbbuchung])[plose_MWSTBetragWaehrungAbbuchung] FROM [tblPLOSE_Details]
INNER JOIN tblPLOSE_Produktbeschreibung ON [plp_ProductCode]=[plose_ProduktCode]
INNER JOIN Adressen ON tblPLOSE_Details.plose_POLSEKundennummer = Adressen.PLOSEKundenNr
INNER JOIN tblSteuernummern ON Adressen.AdressenNr = tblSteuernummern.AdressenNr AND tblSteuernummern.LandKZ = tblPLOSE_Produktbeschreibung.plp_Land
WHERE dbo.tblSteuernummern.AdressenNr = " & varUStVAn_KuNr & " AND (dbo.tblSteuernummern.UStV = 1) AND plose_Archiv <> 1 AND plose_Fakturiert = 1 AND plose_LieferantCode IN (0,1,7) AND cast(plose_RechnungsDatum as date) >= '" & invoiceDate.ToShortDateString & "' and Adressen.AdressenNr = " & varUStVAn_KuNr & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
group by plose_POLSEKundennummer"
@@ -441,13 +470,52 @@ Public Class cMDMFunctionsAllgemein
For Each r As DataRow In dtPLOSE.Rows
Dim UST_org = CDbl(r.Item("plose_MWSTBetragWaehrungAbbuchung"))
If UST_org <> 0 Then
summeSchnittstelle += UST_org
summeAlteSchnittstelle += UST_org
End If
Next
End If
Return summeSchnittstelle
If calcSummeNeueSchnitttelle Then
Dim sqlPLOSE = "select plInv_PLOSEKundennummer, sum([plInv_MWSTBetrag])[plInv_MWSTBetrag], ISNULL([plInv_Currency],'') as plInv_Currency FROM [tblPLOSE_Inv_Data]
INNER JOIN Adressen on PLOSEKundenNr=plInv_PLOSEKundennummer
INNER JOIN dbo.tblSteuernummern ON dbo.tblSteuernummern.AdressenNr = dbo.Adressen.AdressenNr and [tblPLOSE_Inv_Data].plInv_SupplierCountry = tblSteuernummern.LandKZ
WHERE dbo.tblSteuernummern.AdressenNr = " & varUStVAn_KuNr & " AND (dbo.tblSteuernummern.UStV = 1) AND plInv_Archiv <> 1 AND plInv_ArchiviertDatum is null AND cast(plInv_SupplierRechnungsDatum as date) >= '" & invoiceDate.ToShortDateString & "' and Adressen.AdressenNr = " & varUStVAn_KuNr & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
group by plInv_PLOSEKundennummer, plInv_Currency"
Dim dtPLOSE As DataTable = sql.loadDgvBySql(sqlPLOSE, "FMZOLL")
For Each r As DataRow In dtPLOSE.Rows
Dim UST_org = CDbl(r.Item("plInv_MWSTBetrag"))
If UST_org <> 0 Then
Dim Weahrung As String = IIf(r.Item("plInv_Currency") IsNot Nothing, r.Item("plInv_Currency"), "")
If Weahrung <> "" Then
If Weahrung <> "EUR" Then
Dim kurs As New cEZB_Waehrungskurse(Weahrung)
Dim UST_EUR As Double = 0
UST_EUR = Math.Round((UST_org / kurs.ezb_kurs), 2) '+ (UST_org Mod Math.Round(kurs.ezb_kurs, 2)), ")"
summeNeueSchnittstelle += UST_EUR
Else Weahrung = "EUR"
summeNeueSchnittstelle += UST_org
End If
End If
End If
Next
End If
Return summeAlteSchnittstelle + summeNeueSchnittstelle
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodBase.GetCurrentMethod.Name, VERAG_PROG_ALLGEMEIN.ERROR_OP.LOG)
@@ -458,7 +526,7 @@ Public Class cMDMFunctionsAllgemein
End Function
Shared Function UStVKunden_Summen_lesen_Vorschau_IT(varUStVAn_KuNr As Integer, invoiceDate As Date, calcSum As Boolean) As Double
Shared Function UStVKunden_Summen_lesen_Vorschau_IT(varUStVAn_KuNr As Integer, landKZ As String, invoiceDate As Date, calcSum As Boolean) As Double
' Dim qdf As DAO.QueryDef
' Dim rst As DAO.Recordset
@@ -531,7 +599,7 @@ Public Class cMDMFunctionsAllgemein
End Function
Shared Function UStVKunden_Summen_lesen_Vorschau_MSE(varUStVAn_KuNr As Integer, invoiceDate As Date, calcSumalteSchnittstelle As Boolean, calcSumneueSchnittstelle As Boolean) As Double
Shared Function UStVKunden_Summen_lesen_Vorschau_MSE(varUStVAn_KuNr As Integer, landKZ As String, invoiceDate As Date, calcSumalteSchnittstelle As Boolean, calcSumneueSchnittstelle As Boolean) As Double
'Return 0
' dtmRechnungsdatum = IIf(Date > DateSerial(Year(Of Date), 6, 30), DateSerial(Year(Of Date), 1, 1), DateSerial(Year(Of Date)() - 1, 1, 1))
'1850 strParameter = ParameterBereitstellen(varUStVAn_KuNr, dtmRechnungsdatum)
@@ -563,7 +631,7 @@ Public Class cMDMFunctionsAllgemein
dbo.[Länderverzeichnis für die Außenhandelsstatistik] ON dbo.tblSteuernummern.LandNr = dbo.[Länderverzeichnis für die Außenhandelsstatistik].LandNr AND
dbo.tblMSETransactionsArchiv.[Transaction Country] = dbo.[Länderverzeichnis für die Außenhandelsstatistik].LandKz
WHERE (dbo.tblSteuernummern.AdressenNr = " & varUStVAn_KuNr & ") AND (dbo.tblSteuernummern.UStV = 1) AND (dbo.tblMSETransactionsArchiv.[Invoice Date] >= '" & invoiceDate.ToShortDateString & "') AND
(dbo.tblMSETransactionsArchiv.[Original VAT Amount] <> 0) AND (dbo.tblMSETransactionsArchiv.UStVAn_ID IS NULL)
(dbo.tblMSETransactionsArchiv.[Original VAT Amount] <> 0) AND (dbo.tblMSETransactionsArchiv.UStVAn_ID IS NULL) " & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
GROUP BY dbo.tblSteuernummern.AdressenNr, dbo.tblSteuernummern.LandNr, dbo.tblMSETransactionsArchiv.[Invoice Date], dbo.tblMSETransactionsArchiv.[Original Currency]
ORDER BY dbo.tblSteuernummern.AdressenNr, dbo.tblSteuernummern.LandNr, dbo.tblMSETransactionsArchiv.[Invoice Date], dbo.tblMSETransactionsArchiv.[Original Currency] "
@@ -586,8 +654,8 @@ Public Class cMDMFunctionsAllgemein
left join [VERAG].[dbo].[tblMSETransactions] as trans on bills.[transaction_id] = trans.[transaction_id]
left join [VERAG].[dbo].[tblMSECustomers] as cust on cust.partner_customer_number = trans.partner_haulier_id
left join [VERAG].[dbo].[tblMSEInvoices] as inv on inv.invoice_id = bills.invoice_number
left join dbo.tblSteuernummern on dbo.tblSteuernummern.AdressenNr = trans.partner_haulier_id
where bills.invoice_date >= '" & invoiceDate.ToShortDateString & "' and inv.archiv <> 1 and dbo.tblSteuernummern.UStV = 1 and trans.charged = 1 and cust.[partner_customer_number] = " & varUStVAn_KuNr & "
left join dbo.tblSteuernummern on dbo.tblSteuernummern.AdressenNr = trans.partner_haulier_id and dbo.tblSteuernummern.LandKZ = trans.transaction_country
where bills.invoice_date >= '" & invoiceDate.ToShortDateString & "' and inv.archiv <> 1 and dbo.tblSteuernummern.UStV = 1 and trans.charged = 1 and cust.[partner_customer_number] = " & varUStVAn_KuNr & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
group by bills.invoice_date, bills.invoice_number, cust.[customer_id], bills.specification_page_name, trans.transaction_country,trans.original_currency) as temp"
Dim dtMSENeut As DataTable = sql.loadDgvBySql(sqlFMZollDatenNEU, "FMZOLL")
@@ -614,7 +682,7 @@ Public Class cMDMFunctionsAllgemein
End Function
Shared Function UStVKunden_Summen_lesen_Vorschau_UTA(varUStVAn_KuNr As Integer, invoiceDate As Date, calcSumalteSchnittstelle As Boolean, calcSumneueSchnittstelle As Boolean) As Double
Shared Function UStVKunden_Summen_lesen_Vorschau_UTA(varUStVAn_KuNr As Integer, landKZ As String, invoiceDate As Date, calcSumalteSchnittstelle As Boolean, calcSumneueSchnittstelle As Boolean) As Double
'Return 0
' Dim qdf As DAO.QueryDef
' Dim rst As DAO.Recordset
@@ -667,7 +735,7 @@ Public Class cMDMFunctionsAllgemein
dbo.[Länderverzeichnis für die Außenhandelsstatistik] ON dbo.tblSteuernummern.LandNr = dbo.[Länderverzeichnis für die Außenhandelsstatistik].LandNr AND
dbo.tblUTAArchiv.Lieferland = dbo.[Länderverzeichnis für die Außenhandelsstatistik].LandKz_ISO_3
WHERE (dbo.tblSteuernummern.AdressenNr = " & varUStVAn_KuNr & ") AND (dbo.tblSteuernummern.UStV = 1) AND (dbo.tblUTAArchiv.UStVAn_ID IS NULL) AND
(dbo.tblUTAArchiv.Rechnungsdatum >= '" & invoiceDate.ToShortDateString & "') AND (dbo.tblUTAArchiv.Gesamtbetrag_Umsatzsteuer_in_Darstellwährung <> 0)
(dbo.tblUTAArchiv.Rechnungsdatum >= '" & invoiceDate.ToShortDateString & "') AND (dbo.tblUTAArchiv.Gesamtbetrag_Umsatzsteuer_in_Darstellwährung <> 0) " & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
GROUP BY dbo.tblSteuernummern.AdressenNr, dbo.tblSteuernummern.LandNr
ORDER BY dbo.tblSteuernummern.AdressenNr, dbo.tblSteuernummern.LandNr"
@@ -691,7 +759,7 @@ Public Class cMDMFunctionsAllgemein
dbo.[Länderverzeichnis für die Außenhandelsstatistik] ON dbo.tblSteuernummern.LandNr = dbo.[Länderverzeichnis für die Außenhandelsstatistik].LandNr AND
dbo.tblUTAImportNew.Lieferland = dbo.[Länderverzeichnis für die Außenhandelsstatistik].LandKz_ISO_3
WHERE (dbo.tblSteuernummern.AdressenNr = " & varUStVAn_KuNr & ") AND (dbo.tblSteuernummern.UStV = 1) AND (dbo.tblUTAImportNew.archiv IS NULL) AND (dbo.tblUTAImportNew.charged = 1) AND
(dbo.tblUTAImportNew.Rechnungsdatum >= '" & invoiceDate.ToShortDateString & "') AND (dbo.tblUTAImportNew.Gesamtbetrag_Umsatzsteuer_in_Darstellwährung <> 0)
(dbo.tblUTAImportNew.Rechnungsdatum >= '" & invoiceDate.ToShortDateString & "') AND (dbo.tblUTAImportNew.Gesamtbetrag_Umsatzsteuer_in_Darstellwährung <> 0) " & IIf(landKZ = "SRB" OrElse landKZ = "BIH", " AND dbo.tblSteuernummern.LandKZ <> 'HU'", "") & "
GROUP BY dbo.tblSteuernummern.AdressenNr, dbo.tblSteuernummern.LandNr
ORDER BY dbo.tblSteuernummern.AdressenNr, dbo.tblSteuernummern.LandNr"
@@ -722,4 +790,5 @@ Public Class cMDMFunctionsAllgemein
End Try
End Function
End Class

View File

@@ -98,6 +98,12 @@ Public Class cMitarbeiter
Property mit_timasMehrereFirmen As Boolean = False
Property mit_timasFirmen As Object = Nothing
Property mit_Notfall_Name As Object = Nothing
Property mit_Notfall_Handy As Object = Nothing
Property mit_Notfall_Mail As Object = Nothing
Dim SQL As New SQL
@@ -210,6 +216,9 @@ Public Class cMitarbeiter
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("mit_ausstempelnBeiBeenden", mit_ausstempelnBeiBeenden))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("mit_timasFirmen", mit_timasFirmen))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("mit_timasMehrereFirmen", mit_timasMehrereFirmen))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("mit_Notfall_Name", mit_Notfall_Name))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("mit_Notfall_Handy", mit_Notfall_Handy))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("mit_Notfall_Mail", mit_Notfall_Mail))
@@ -416,6 +425,10 @@ Public Class cMitarbeiter
If Not dr.Item("mit_timasFirmen") Is DBNull.Value Then Me.mit_timasFirmen = dr.Item("mit_timasFirmen")
Me.mit_timasMehrereFirmen = dr.Item("mit_timasMehrereFirmen")
If Not dr.Item("mit_Notfall_Handy") Is DBNull.Value Then Me.mit_Notfall_Handy = dr.Item("mit_Notfall_Handy")
If Not dr.Item("mit_Notfall_Name") Is DBNull.Value Then Me.mit_Notfall_Name = dr.Item("mit_Notfall_Name")
If Not dr.Item("mit_Notfall_Mail") Is DBNull.Value Then Me.mit_Notfall_Mail = dr.Item("mit_Notfall_Mail")
Catch ex As Exception
MsgBox(System.Reflection.MethodInfo.GetCurrentMethod.Name & ": Fehler beim Einlesen der Mitarbeiter-Details " & vbCrLf & vbCrLf & ex.Message, MsgBoxStyle.Exclamation)

View File

@@ -171,7 +171,7 @@ Public Class cRMC
where cast(rmc_reDatum as date) between @von and @bis and AdressenNr=@AdressenNr
AND rmc_landKZ ='" & LandKZ & "'" & IIf(Not Archiv, " And rmc_archiv = 0 ", "") & "
group by rmc_reDatum,rmc_kdNr,[rmc_reNr],[rmc_waehrung], rmc_daId
having sum([rmc_betragMWST])>0
having sum([rmc_betragMWST])<>0
order by rmc_reDatum", conn)
cmd.Parameters.AddWithValue("@von", von)

View File

@@ -117,6 +117,7 @@ Public Class cRechnungsausgang
Property FakturierungsGruppe As String = ""
Property TextZZ As Object = Nothing
Property ForceSteuerschlüssel As Object = Nothing
Property Automailversand As Boolean = False
' FROM [VERAG as object=nothing.[dbo as object=nothing.[Rechnungsausgang as object=nothing
@@ -360,6 +361,7 @@ Public Class cRechnungsausgang
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("FakturierungsGruppe", FakturierungsGruppe))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("TextZZ", TextZZ))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("ForceSteuerschlüssel", ForceSteuerschlüssel))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Automailversand", Automailversand))
Return list
End Function

View File

@@ -66,6 +66,7 @@ Public Class cSDL
Property BelegNr As Object = Nothing
Property Nationalitaet As Object = Nothing
Property CO2Kategorie As Object = Nothing
Property CVCNr As Object = Nothing
Public hasentry
Dim SQL As New SQL
@@ -156,6 +157,7 @@ Public Class cSDL
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("BelegNr", BelegNr))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Nationalitaet", Nationalitaet))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("CO2Kategorie", CO2Kategorie))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("CVCNr", CVCNr))
Return list
End Function

View File

@@ -846,7 +846,6 @@ Public Class cSMS
SMS.sms_Vorwahl = ""
SMS.sms_Handynummer = "00436644178557" 'AVISO.FahrerHandy.trim 'txtHandyNummer.Text.Replace(" ", "").Replace("-", "").Replace("/", "")
SMS.sms_Nachricht = "Statusmeldung: " & vbNewLine & "https://status.app.verag.ag/aviso-status/" & VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(AVISO.AvisoID)
'SMS.sms_Nachricht = "Statusmeldung: " & vbNewLine & "https://login.verag.ag/status.aspx?AvisoId=" & VERAG_PROG_ALLGEMEIN.cCryptography3.Encrypt(AVISO.AvisoID)
SMS.sms_Account = absenderAccount

View File

@@ -474,6 +474,7 @@ Public Class cSendungen
a.sndabr_anzahl = SQL.checkNullReturnValue(dr2.Item("sndabr_anzahl"), Nothing)
a.sndabr_einzelPreis = SQL.checkNullReturnValue(dr2.Item("sndabr_einzelPreis"), Nothing)
a.sndabr_preis = SQL.checkNullReturnValue(dr2.Item("sndabr_preis"), Nothing)
a.sndabr_LeistungsNr = SQL.checkNullReturnValue(dr2.Item("sndabr_LeistungsNr"), Nothing)
Me.ABRECHNUNG.Add(a)
End While
@@ -846,6 +847,7 @@ Public Class cSendungAbrechnung
Property sndabr_anzahl As Integer = Nothing
Property sndabr_einzelPreis As Object = Nothing
Property sndabr_preis As Object = Nothing
Property sndabr_LeistungsNr As Object = Nothing
Dim SQL As New SQL
@@ -860,7 +862,7 @@ Public Class cSendungAbrechnung
Me.sndabr_wert = sndabr_wert
End Sub
Sub New(sndabr_sendId, sndabr_beteiligter, sndabr_abrArt, sndabr_wert, sndabr_bezeichnung, sndabr_anzahl, sndabr_einzelPreis, sndabr_preis)
Sub New(sndabr_sendId, sndabr_beteiligter, sndabr_abrArt, sndabr_wert, sndabr_bezeichnung, sndabr_anzahl, sndabr_einzelPreis, sndabr_preis, sndabr_LeistungsNr)
Me.sndabr_sendId = sndabr_sendId
Me.sndabr_beteiligter = sndabr_beteiligter
Me.sndabr_abrArt = sndabr_abrArt
@@ -869,6 +871,7 @@ Public Class cSendungAbrechnung
Me.sndabr_anzahl = sndabr_anzahl
Me.sndabr_einzelPreis = sndabr_einzelPreis
Me.sndabr_preis = sndabr_preis
Me.sndabr_LeistungsNr = sndabr_LeistungsNr
End Sub
Function getParameterList() As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable)
Dim list As New List(Of VERAG_PROG_ALLGEMEIN.SQLVariable)
@@ -881,6 +884,7 @@ Public Class cSendungAbrechnung
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("sndabr_anzahl", sndabr_anzahl))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("sndabr_einzelPreis", sndabr_einzelPreis))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("sndabr_preis", sndabr_preis))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("sndabr_LeistungsNr", sndabr_LeistungsNr))
Return list
End Function

View File

@@ -193,7 +193,7 @@ Public Class cTrdInvoice
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand(" SELECT tblTrdinInvoice.Rechnungsdatum, tblTrdinInvoice.Rechnungsnummer, tblTrdinInvoice.SteuerbetragLokal, tblTrdinInvoice.UStVAn_ID
Using cmd As New SqlCommand(" SELECT tblTrdinInvoice.Rechnungsdatum, tblTrdinInvoice.Rechnungsnummer, tblTrdinInvoice.SteuerbetragLokal, tblTrdinInvoice.UStVAn_ID, tblTrdinInvoice.FilialenNr
FROM tblTrdinInvoice
WHERE tblTrdinInvoice.Rechnungsdatum Between @von And @bis AND tblTrdinInvoice.SteuerbetragLokal<>0 AND tblTrdinInvoice.RechnungsKundenNr=@AdressenNr AND tblTrdinInvoice.WährungLokal='EUR'" & IIf(Archiv, " ", " AND isnull(tblTrdinInvoice.UStVAn_ID,0) = 0 ") & "
ORDER BY tblTrdinInvoice.Rechnungsdatum, tblTrdinInvoice.Rechnungsnummer", conn)

View File

@@ -155,7 +155,7 @@ Public Class cUIDPruefung
Select Case VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA
Case "AMBAR" : where = " And Filialen.FilialenNr IN (5701)"
Case "IMEX" : where = " And Filialen.FilialenNr IN (5501)"
Case "ATILLA" : where = " And Filialen.FilialenNr IN (4801 )"
Case "ATILLA" : where = " And Filialen.FilialenNr IN (4801)"
Case "UNISPED" : where = " AND Filialen.firma='UNISPED' "
Case Else : where = " AND Filialen.firma='VERAG' " '" And isnull(FilialenNr,'') Not IN (5501,5701)"
End Select

View File

@@ -970,342 +970,353 @@ Public Class cUTA
Dim curChecksumme As Double
Dim lngRecordCount As Long
'Datei auf Fehler prüfen!
Do While (objFileRead.Peek() > -1)
Dim strZeile = objFileRead.ReadLine()
Try
Select Case Mid(strZeile, 1, 2)
Case "10"
booHeaderVorhanden = True
lngRecordCount = lngRecordCount + 1
Case "20"
' Meldung bei nicht vorhandenen Haeder.
If Not booHeaderVorhanden Then
MsgBox("Datei kann wegen fehlenden Header nicht verarbeitet werden.")
objFileRead.Close()
Return False
End If
lngRecordCount = lngRecordCount + 1
Case "90"
' Meldung bei nicht vorhandenen Haeder.
If Not booHeaderVorhanden Then
MsgBox("Datei kann wegen fehlenden Header nicht verarbeitet werden.")
objFileRead.Close()
Return False
End If
'Datei auf Fehler prüfen!
Do While (objFileRead.Peek() > -1)
Dim strZeile = objFileRead.ReadLine()
booTrailerVorhanden = True
lngRecordCount = lngRecordCount + 1
Select Case Mid(strZeile, 1, 2)
Case "10"
booHeaderVorhanden = True
lngRecordCount = lngRecordCount + 1
Case "20"
' Meldung bei nicht vorhandenen Haeder.
If Not booHeaderVorhanden Then
MsgBox("Datei kann wegen fehlenden Header nicht verarbeitet werden.")
objFileRead.Close()
Return False
End If
' Prüfsumme Anzahl der Sätze im File ohne Header und Trailer.
If Trim(Mid(strZeile, 3, 13)) <> (lngRecordCount) Then
MsgBox("Fehler: " & vbNewLine & "Prüfsumme in der Datei stimmt nicht mit der Zeilenanzahl der Datei überein! " & vbNewLine & "Record Count: " & Trim(Mid(strZeile, 3, 13)) & vbCrLf & "Prüfsumme: " & (lngRecordCount) & vbCrLf)
objFileRead.Close()
Return False
End If
lngRecordCount = lngRecordCount + 1
' Meldung bei Prüfsummenfehler.
If booPrüfziffernfehler Then
MsgBox("Datei kann wegen Prüfsummenfehler nicht verarbeitet werden.")
objFileRead.Close()
End If
Case Else
booPrüfziffernfehler = True
End Select
Loop
Dim lngPKLine As Long = 0
lngRecordCount = 0
'gleicher PKFileName wird nun aus CLFHeader gelöscht. CASCADE löscht dann zugehörige CLFBody und CLFTrailer.
'If Not SQL.doSQL("DELETE tblUTAHeaderNew.ErstellDatumUhrzeit, tblUTAHeaderNew.Übertragungsnummer FROM tblUTAHeaderNew WHERE (((tblUTAHeaderNew.ErstellDatumUhrzeit)=" & Format$(dtmErstellDatumUhrzeit, "\#mm\/dd\/yyyy hh\:nn\:ss AM/PM\#") & ") AND ((tblUTAHeaderNew.Übertragungsnummer)=" & lngÜbertragungsnummer, "FMZOLL") Then
' MsgBox("Fehler beim Löschen des CLF-Headers")
' objFileRead.Close()
' Return False
'End If
'If Not SQL.doSQL("UPDATE CLF SET PKFileName = '" & fi.Name.ToString & "'", "FMZOLL") Then
' MsgBox("Fehler beim Update der CLF-Nr")
' objFileRead.Close()
' Return False
'End If
objFileRead.DiscardBufferedData()
objFileRead.BaseStream.Seek(0, System.IO.SeekOrigin.Begin)
Do While (objFileRead.Peek() > -1)
Dim strZeile = objFileRead.ReadLine()
Select Case Mid(strZeile, 1, 2)
Case "10"
booHeaderVorhanden = True
lngRecordCount = lngRecordCount + 1
dtmErstellDatumUhrzeit = DateSerial(Mid(strZeile, 35, 4), Mid(strZeile, 32, 2), Mid(strZeile, 29, 2)) & " " & TimeSerial(Mid(strZeile, 40, 2), Mid(strZeile, 43, 2), Mid(strZeile, 46, 2))
lngÜbertragungsnummer = Mid(strZeile, 61, 6)
'Dim ext = CInt(fi.Extension.Remove(0, 1))
Dim clfHeader As New cUTA.UTAHeader(lngÜbertragungsnummer, dtmErstellDatumUhrzeit)
With clfHeader
.Absender_ID = Mid(strZeile, 10, 6)
.Empfänger_ID = Mid(strZeile, 23, 6)
.Filler_Feld_5 = IIf(Trim(Mid(strZeile, 39, 1)) = "", Nothing, Trim(Mid(strZeile, 39, 1)))
.Abrechnungsnummer = IIf(Trim(Mid(strZeile, 48, 13)) = Nothing, "", Trim(Mid(strZeile, 48, 13)))
.DTF_Format = IIf(Trim(Mid(strZeile, 67, 6)) = Nothing, "", Trim(Mid(strZeile, 67, 6)))
.SAVE()
End With
Case "20"
lngRecordCount = lngRecordCount + 1
lngÜbertragungsposition = lngÜbertragungsposition + 1
Dim clfBody As New cUTA.UTABody(lngÜbertragungsnummer, lngÜbertragungsposition, dtmErstellDatumUhrzeit)
With clfBody
.Übertragungsnummer = lngÜbertragungsnummer
.Übertragungsposition = lngÜbertragungsposition
.Abrechnungsnummer = Mid(strZeile, 3, 13)
.[Datum_für_Lieferungen_und_Leistungen_bis] = DateSerial(Mid(strZeile, 20, 4), Mid(strZeile, 18, 2), Mid(strZeile, 16, 2))
.[Rechnungsempfänger_Kundennummer] = Mid(strZeile, 24, 13)
.[Abrechnungsdatum] = DateSerial(Mid(strZeile, 41, 4), Mid(strZeile, 39, 2), Mid(strZeile, 37, 2))
.[Kundennummer] = Mid(strZeile, 45, 13)
.[Kartennummer] = IIf(Trim(Mid(strZeile, 58, 19)) = "", Nothing, Trim(Mid(strZeile, 58, 19)))
.[Belegdatum] = DateSerial(Mid(strZeile, 81, 4), Mid(strZeile, 79, 2), Mid(strZeile, 77, 2))
.[Akzeptanzstellennummer] = Mid(strZeile, 85, 13)
.[Standort_der_Akzeptanzstelle] = IIf(Trim(Mid(strZeile, 98, 25)) = "", Nothing, Trim(Mid(strZeile, 98, 25)))
.[Lieferland] = IIf(Trim(Mid(strZeile, 123, 3)) = "", Nothing, Trim(Mid(strZeile, 123, 3)))
.[Belegnummer_des_Lieferanten] = IIf(Trim(Mid(strZeile, 126, 13)) = "", Nothing, Trim(Mid(strZeile, 126, 13)))
.[Kilometerstand] = Mid(strZeile, 139, 8)
.[Fakturierwarenart] = IIf(Trim(Mid(strZeile, 147, 5)) = "", Nothing, Trim(Mid(strZeile, 147, 5)))
.[Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen] = IIf(Trim(Mid(strZeile, 152, 1)) = "", Nothing, Trim(Mid(strZeile, 152, 1)))
.[Menge] = Mid(strZeile, 153, 10) / 100
.[SB_BT] = IIf(Trim(Mid(strZeile, 163, 1)) = "", Nothing, Trim(Mid(strZeile, 163, 1)))
.[Umsatzsteuerprozentsatz] = Mid(strZeile, 164, 5) / 10000
.[Lieferlandwährung_ISO] = IIf(Trim(Mid(strZeile, 169, 3)) = "", Nothing, Trim(Mid(strZeile, 169, 3)))
.[Einzelpreis_Brutto_in_Lieferlandwährung] = Mid(strZeile, 172, 11) / 100
.[Einzelpreis_Netto_in_Lieferlandwährung] = Mid(strZeile, 183, 11) / 100
.[Betrag_Service_in_Lieferlandwährung] = Mid(strZeile, 194, 11) / 100
.[Betrag_Nachlass_in_Lieferlandwährung] = Mid(strZeile, 205, 11) / 100
.[Gesamtbetrag_Netto_in_Lieferlandwährung] = Mid(strZeile, 216, 11) / 100
.[Gesamtbetrag_Brutto_in_Lieferlandwährung] = Mid(strZeile, 227, 11) / 100
.[Darstellwährung_ISO] = IIf(Trim(Mid(strZeile, 238, 3)) = "", Nothing, Trim(Mid(strZeile, 238, 3)))
.[Betrag_Service_in_Darstellwährung] = Mid(strZeile, 241, 11) / 100
.[Betrag_Nachlass_in_Darstellwährung] = Mid(strZeile, 252, 11) / 100
.[Gesamtbetrag_Netto_in_Darstellwährung] = Mid(strZeile, 263, 11) / 100
.[Gesamtbetrag_Umsatzsteuer_in_Darstellwährung] = Mid(strZeile, 274, 11) / 100
.[Gesamtbetrag_Brutto_in_Darstellwährung] = Mid(strZeile, 285, 11) / 100
.[Prägetext_i_d_R_KFZ_Kennzeichen] = IIf(Trim(Mid(strZeile, 296, 16)) = "", Nothing, Trim(Mid(strZeile, 296, 16)))
.[Kunden_Kostenstelle_1] = IIf(Trim(Mid(strZeile, 312, 20)) = "", Nothing, Trim(Mid(strZeile, 312, 20)))
.[Kartentyp] = IIf(Trim(Mid(strZeile, 332, 8)) = "", Nothing, Trim(Mid(strZeile, 332, 8)))
.[Filler_Feld_35] = IIf(Trim(Mid(strZeile, 340, 1)) = "", Nothing, Trim(Mid(strZeile, 340, 1)))
.[Filler_Feld_36] = IIf(Trim(Mid(strZeile, 341, 3)) = "", Nothing, Trim(Mid(strZeile, 341, 3)))
.[KZ_Autobahn] = IIf(Trim(Mid(strZeile, 344, 1)) = "", Nothing, Trim(Mid(strZeile, 344, 1)))
.[INFO_Feld] = IIf(Trim(Mid(strZeile, 345, 18)) = "", Nothing, Trim(Mid(strZeile, 345, 18)))
.[KFZ_Kennzeichen] = IIf(Trim(Mid(strZeile, 363, 16)) = "", Nothing, Trim(Mid(strZeile, 363, 16)))
.[Filler_Feld_40] = IIf(Trim(Mid(strZeile, 379, 1)) = "", Nothing, Trim(Mid(strZeile, 379, 1)))
.[Buchungsart] = IIf(Trim(Mid(strZeile, 380, 1)) = "", Nothing, Trim(Mid(strZeile, 380, 1)))
.[Buchungsgrund] = IIf(Trim(Mid(strZeile, 381, 1)) = "", Nothing, Trim(Mid(strZeile, 381, 1)))
.[Filler_Feld_43] = IIf(Trim(Mid(strZeile, 382, 1)) = "", Nothing, Trim(Mid(strZeile, 382, 1)))
.[Informationsbeleg] = IIf(Trim(Mid(strZeile, 383, 1)) = "", Nothing, Trim(Mid(strZeile, 383, 1)))
.[Belegherkunft] = IIf(Trim(Mid(strZeile, 384, 1)) = "", Nothing, Trim(Mid(strZeile, 384, 1)))
.[Filler_Feld_46] = IIf(Trim(Mid(strZeile, 385, 14)) = "", Nothing, Trim(Mid(strZeile, 385, 14)))
.[Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen] = Mid(strZeile, 399, 13) / 10000
.[Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen] = Mid(strZeile, 412, 13) / 10000
.[Rechnungsdatum] = DateSerial(Mid(strZeile, 429, 4), Mid(strZeile, 427, 2), Mid(strZeile, 425, 2))
.[Umsatzsteuerprozentsatz_informativ] = Mid(strZeile, 433, 5) / 10000
.[Betrag_Nachlass_in_Lieferlandwährung_Umsatzsteuer_informativ] = Mid(strZeile, 438, 11) / 100
.[Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ] = Mid(strZeile, 449, 11) / 100
.[Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ] = Mid(strZeile, 460, 11) / 100
.[Fälligkeitsdatum] = DateSerial(Mid(strZeile, 475, 4), Mid(strZeile, 473, 2), Mid(strZeile, 471, 2))
.[Zahlungsziel_in_Tagen] = Mid(strZeile, 479, 3)
.[Zahlungsart] = IIf(Trim(Mid(strZeile, 482, 8)) = "", Nothing, Trim(Mid(strZeile, 482, 8)))
.[TC_Rechnungsnummer_gegenüber_dem_Nutzer] = IIf(Trim(Mid(strZeile, 490, 20)) = "", Nothing, Trim(Mid(strZeile, 490, 20)))
.[TC_Rechnungsdatum] = DateSerial(Mid(strZeile, 514, 4), Mid(strZeile, 512, 2), Mid(strZeile, 510, 2))
.[Zahlungszielgruppe] = IIf(Trim(Mid(strZeile, 518, 7)) = "", Nothing, Trim(Mid(strZeile, 518, 7)))
.[Kunden_Kostenstelle_2] = IIf(Trim(Mid(strZeile, 525, 20)) = "", Nothing, Trim(Mid(strZeile, 525, 20)))
.[Lieferzeit] = IIf(Trim(Mid(strZeile, 545, 6)) = "", Nothing, Trim(Mid(strZeile, 545, 6)))
.[Fremdkartennummer] = IIf(Trim(Mid(strZeile, 551, 20)) = "", Nothing, Trim(Mid(strZeile, 551, 20)))
.[OnBoardUnitID] = IIf(Trim(Mid(strZeile, 571, 20)) = "", Nothing, Trim(Mid(strZeile, 571, 20)))
.[KFZ_Kennzeichen_komprimiert] = IIf(Trim(Mid(strZeile, 591, 16)) = "", Nothing, Trim(Mid(strZeile, 591, 16)))
.[Kartenkategorie] = IIf(Trim(Mid(strZeile, 607, 8)) = "", Nothing, Trim(Mid(strZeile, 607, 8)))
.[Rechnungsnummer_pro_Lieferland] = Mid(strZeile, 615, 13)
.[Autobahnauffahrt] = IIf(Trim(Mid(strZeile, 628, 40)) = "", Nothing, Trim(Mid(strZeile, 628, 40)))
.[Autobahnausfahrt] = IIf(Trim(Mid(strZeile, 668, 40)) = "", Nothing, Trim(Mid(strZeile, 668, 40)))
.[Rabattschlüssel_der_französischen_Autobahngesellschaften] = IIf(Trim(Mid(strZeile, 708, 1)) = "", Nothing, Trim(Mid(strZeile, 708, 1)))
.[Nummer_Belastungsanzeige] = Mid(strZeile, 709, 13)
.[Betreuungsstelle] = IIf(Trim(Mid(strZeile, 722, 20)) = "", Nothing, Trim(Mid(strZeile, 722, 20)))
.[Filler_Feld_72] = IIf(Trim(Mid(strZeile, 742, 20)) = "", Nothing, Trim(Mid(strZeile, 742, 20)))
.[Akzeptanz_Medium] = IIf(Trim(Mid(strZeile, 762, 20)) = "", Nothing, Trim(Mid(strZeile, 762, 20)))
.[Steuerkategorie] = IIf(Trim(Mid(strZeile, 782, 8)) = "", Nothing, Trim(Mid(strZeile, 782, 8)))
.[UTA_Beleg_ID] = Mid(strZeile, 790, 11)
.[UTA_Normalbeleg_ID] = Mid(strZeile, 801, 11)
.[Gebühren_Bescheinigung_von] = DateSerial(Mid(strZeile, 816, 4), Mid(strZeile, 814, 2), Mid(strZeile, 812, 2))
.[Gebühren_Bescheinigung_bis] = DateSerial(Mid(strZeile, 824, 4), Mid(strZeile, 822, 2), Mid(strZeile, 820, 2))
.[Herausgeber_Nutzer_Nummer] = IIf(Trim(Mid(strZeile, 828, 20)) = "", Nothing, Trim(Mid(strZeile, 828, 20)))
.[Maßeinheit] = IIf(Trim(Mid(strZeile, 848, 8)) = "", Nothing, Trim(Mid(strZeile, 848, 8)))
.[Land_der_Akzeptanzstelle] = IIf(Trim(Mid(strZeile, 856, 3)) = "", Nothing, Trim(Mid(strZeile, 856, 3)))
.[Postleitzahl_der_Akzeptanzstelle] = IIf(Trim(Mid(strZeile, 859, 7)) = "", Nothing, Trim(Mid(strZeile, 859, 7)))
.[Steuerliches_Lieferland] = IIf(Trim(Mid(strZeile, 866, 3)) = "", Nothing, Trim(Mid(strZeile, 866, 3)))
.[Steuerliche_Produktgruppe] = IIf(Trim(Mid(strZeile, 869, 5)) = "", Nothing, Trim(Mid(strZeile, 869, 5)))
.[Leistungsort_verlagerbar] = IIf(Trim(Mid(strZeile, 874, 1)) = "", Nothing, Trim(Mid(strZeile, 874, 1)))
Select Case .[Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen]
Case "0" 'positiv
curChecksumme = curChecksumme + .[Gesamtbetrag_Brutto_in_Darstellwährung]
Case "1" 'negativ
curChecksumme = curChecksumme - .[Gesamtbetrag_Brutto_in_Darstellwährung]
.[Menge] = 0 - .[Menge]
.[Einzelpreis_Brutto_in_Lieferlandwährung] = 0 - .[Einzelpreis_Brutto_in_Lieferlandwährung]
.[Einzelpreis_Netto_in_Lieferlandwährung] = 0 - .[Einzelpreis_Netto_in_Lieferlandwährung]
.[Betrag_Service_in_Lieferlandwährung] = 0 - .[Betrag_Service_in_Lieferlandwährung]
.[Betrag_Nachlass_in_Lieferlandwährung] = 0 - .[Betrag_Nachlass_in_Lieferlandwährung]
.[Gesamtbetrag_Netto_in_Lieferlandwährung] = 0 - .[Gesamtbetrag_Netto_in_Lieferlandwährung]
.[Gesamtbetrag_Brutto_in_Lieferlandwährung] = 0 - .[Gesamtbetrag_Brutto_in_Lieferlandwährung]
.[Betrag_Service_in_Darstellwährung] = 0 - .[Betrag_Service_in_Darstellwährung]
.[Betrag_Nachlass_in_Darstellwährung] = 0 - .[Betrag_Nachlass_in_Darstellwährung]
.[Gesamtbetrag_Netto_in_Darstellwährung] = 0 - .[Gesamtbetrag_Netto_in_Darstellwährung]
.[Gesamtbetrag_Umsatzsteuer_in_Darstellwährung] = 0 - .[Gesamtbetrag_Umsatzsteuer_in_Darstellwährung]
.[Gesamtbetrag_Brutto_in_Darstellwährung] = 0 - .[Gesamtbetrag_Brutto_in_Darstellwährung]
.[Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen] = 0 - .[Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen]
.[Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen] = 0 - .[Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen]
.[Betrag_Nachlass_in_Lieferlandwährung_Umsatzsteuer_informativ] = 0 - .[Betrag_Nachlass_in_Lieferlandwährung_Umsatzsteuer_informativ]
.[Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ] = 0 - .[Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ]
.[Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ] = 0 - .[Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ]
End Select
If onlyTestkunedn Then
'nur KundenNr 100964 und 825040 speichern:
If .[Kundennummer] = 100964 Or .[Kundennummer] = 825040 Then
.SAVE()
End If
Else
.SAVE()
Case "90"
' Meldung bei nicht vorhandenen Haeder.
If Not booHeaderVorhanden Then
MsgBox("Datei kann wegen fehlenden Header nicht verarbeitet werden.")
objFileRead.Close()
Return False
End If
booTrailerVorhanden = True
lngRecordCount = lngRecordCount + 1
'Dim clfArchiv As New cUTA.UTAArchiv(.Belegdatum, .UTA_Beleg_ID)
'clfArchiv.Übertragungsnummer = .Übertragungsnummer
'clfArchiv.ErstellDatumUhrzeit = .ErstellDatumUhrzeit
'clfArchiv.Übertragungsposition = .Übertragungsposition
'clfArchiv.Abrechnungsnummer = .Abrechnungsnummer
'clfArchiv.Datum_für_Lieferungen_und_Leistungen_bis = .Datum_für_Lieferungen_und_Leistungen_bis
'clfArchiv.Rechnungsempfänger_Kundennummer = .Rechnungsempfänger_Kundennummer
'clfArchiv.Abrechnungsdatum = .Abrechnungsdatum
'clfArchiv.Kundennummer = .Kundennummer
'clfArchiv.Kartennummer = .Kartennummer
'clfArchiv.Akzeptanzstellennummer = .Akzeptanzstellennummer
'clfArchiv.Standort_der_Akzeptanzstelle = .Standort_der_Akzeptanzstelle
'clfArchiv.Lieferland = .Lieferland
'clfArchiv.Belegnummer_des_Lieferanten = .Belegnummer_des_Lieferanten
'clfArchiv.Kilometerstand = .Kilometerstand
'clfArchiv.Fakturierwarenart = .Fakturierwarenart
'clfArchiv.Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen = .Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen
'clfArchiv.Menge = .Menge
'clfArchiv.SB_BT = .SB_BT
'clfArchiv.Umsatzsteuerprozentsatz = .Umsatzsteuerprozentsatz
'clfArchiv.Lieferlandwährung_ISO = .Lieferlandwährung_ISO
'clfArchiv.Einzelpreis_Netto_in_Lieferlandwährung = .Einzelpreis_Netto_in_Lieferlandwährung
'clfArchiv.Einzelpreis_Brutto_in_Lieferlandwährung = .Einzelpreis_Brutto_in_Lieferlandwährung
'clfArchiv.Einzelpreis_Netto_in_Lieferlandwährung = .Einzelpreis_Netto_in_Lieferlandwährung
'clfArchiv.Betrag_Service_in_Lieferlandwährung = .Betrag_Service_in_Lieferlandwährung
'clfArchiv.Betrag_Nachlass_in_Lieferlandwährung = .Betrag_Nachlass_in_Lieferlandwährung
'clfArchiv.Gesamtbetrag_Netto_in_Lieferlandwährung = .Gesamtbetrag_Netto_in_Lieferlandwährung
'clfArchiv.Gesamtbetrag_Brutto_in_Lieferlandwährung = .Gesamtbetrag_Brutto_in_Lieferlandwährung
'clfArchiv.Darstellwährung_ISO = .Darstellwährung_ISO
'clfArchiv.Betrag_Service_in_Darstellwährung = .Betrag_Service_in_Darstellwährung
'clfArchiv.Betrag_Nachlass_in_Darstellwährung = .Betrag_Nachlass_in_Darstellwährung
'clfArchiv.Gesamtbetrag_Netto_in_Darstellwährung = .Gesamtbetrag_Netto_in_Darstellwährung
'clfArchiv.Gesamtbetrag_Umsatzsteuer_in_Darstellwährung = .Gesamtbetrag_Umsatzsteuer_in_Darstellwährung
'clfArchiv.Gesamtbetrag_Brutto_in_Darstellwährung = .Gesamtbetrag_Brutto_in_Darstellwährung
'clfArchiv.Prägetext_i_d_R_KFZ_Kennzeichen = .Prägetext_i_d_R_KFZ_Kennzeichen
'clfArchiv.Kunden_Kostenstelle_1 = .Kunden_Kostenstelle_1
'clfArchiv.Kartentyp = .Kartentyp
'clfArchiv.Filler_Feld_35 = .Filler_Feld_35
'clfArchiv.Filler_Feld_36 = .Filler_Feld_36
'clfArchiv.KZ_Autobahn = .KZ_Autobahn
'clfArchiv.INFO_Feld = .INFO_Feld
'clfArchiv.KFZ_Kennzeichen = .KFZ_Kennzeichen
'clfArchiv.Filler_Feld_40 = .Filler_Feld_40
'clfArchiv.Buchungsart = .Buchungsart
'clfArchiv.Buchungsgrund = .Buchungsgrund
'clfArchiv.Filler_Feld_43 = .Filler_Feld_43
'clfArchiv.Informationsbeleg = .Informationsbeleg
'clfArchiv.Belegherkunft = .Belegherkunft
'clfArchiv.Filler_Feld_46 = .Filler_Feld_46
'clfArchiv.Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen = .Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen
'clfArchiv.Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen = .Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen
'clfArchiv.Rechnungsdatum = .Rechnungsdatum
'clfArchiv.Umsatzsteuerprozentsatz_informativ = .Umsatzsteuerprozentsatz_informativ
'clfArchiv.Betrag_Nachlass_in_Lieferlandwährung = .Betrag_Nachlass_in_Lieferlandwährung
'clfArchiv.Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ = .Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ
'clfArchiv.Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ = .Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ
'clfArchiv.Fälligkeitsdatum = .Fälligkeitsdatum
'clfArchiv.Zahlungsziel_in_Tagen = .Zahlungsziel_in_Tagen
'clfArchiv.Zahlungsart = .Zahlungsart
'clfArchiv.TC_Rechnungsnummer_gegenüber_dem_Nutzer = .TC_Rechnungsnummer_gegenüber_dem_Nutzer
'clfArchiv.TC_Rechnungsdatum = .TC_Rechnungsdatum
'clfArchiv.Zahlungszielgruppe = .Zahlungszielgruppe
'clfArchiv.Kunden_Kostenstelle_2 = .Kunden_Kostenstelle_2
'clfArchiv.Lieferzeit = .Lieferzeit
'clfArchiv.Fremdkartennummer = .Fremdkartennummer
'clfArchiv.OnBoardUnitID = .OnBoardUnitID
'clfArchiv.KFZ_Kennzeichen_komprimiert = .KFZ_Kennzeichen_komprimiert
'clfArchiv.Kartenkategorie = .Kartenkategorie
'clfArchiv.Rechnungsnummer_pro_Lieferland = .Rechnungsnummer_pro_Lieferland
'clfArchiv.Autobahnauffahrt = .Autobahnauffahrt
'clfArchiv.Autobahnausfahrt = .Autobahnausfahrt
'clfArchiv.Rabattschlüssel_der_französischen_Autobahngesellschaften = .Rabattschlüssel_der_französischen_Autobahngesellschaften
'clfArchiv.Nummer_Belastungsanzeige = .Nummer_Belastungsanzeige
'clfArchiv.Betreuungsstelle = .Betreuungsstelle
'clfArchiv.Filler_Feld_72 = .Filler_Feld_72
'clfArchiv.Akzeptanz_Medium = .Akzeptanz_Medium
'clfArchiv.Steuerkategorie = .Steuerkategorie
'clfArchiv.UTA_Normalbeleg_ID = .UTA_Normalbeleg_ID
'clfArchiv.Gebühren_Bescheinigung_von = .Gebühren_Bescheinigung_von
'clfArchiv.Gebühren_Bescheinigung_bis = .Gebühren_Bescheinigung_bis
'clfArchiv.Herausgeber_Nutzer_Nummer = .Herausgeber_Nutzer_Nummer
'clfArchiv.Maßeinheit = .Maßeinheit
'clfArchiv.Land_der_Akzeptanzstelle = .Land_der_Akzeptanzstelle
'clfArchiv.Postleitzahl_der_Akzeptanzstelle = .Postleitzahl_der_Akzeptanzstelle
'clfArchiv.Steuerliches_Lieferland = .Steuerliches_Lieferland
'clfArchiv.Steuerliche_Produktgruppe = .Steuerliche_Produktgruppe
'clfArchiv.Leistungsort_verlagerbar = .Leistungsort_verlagerbar
'clfArchiv.SAVE()
' Prüfsumme Anzahl der Sätze im File ohne Header und Trailer.
If Trim(Mid(strZeile, 3, 13)) <> (lngRecordCount) Then
MsgBox("Fehler: " & vbNewLine & "Prüfsumme in der Datei stimmt nicht mit der Zeilenanzahl der Datei überein! " & vbNewLine & "Record Count: " & Trim(Mid(strZeile, 3, 13)) & vbCrLf & "Prüfsumme: " & (lngRecordCount) & vbCrLf)
objFileRead.Close()
Return False
End If
End With
' Meldung bei Prüfsummenfehler.
If booPrüfziffernfehler Then
MsgBox("Datei kann wegen Prüfsummenfehler nicht verarbeitet werden.")
objFileRead.Close()
Case "90"
End If
Case Else
booPrüfziffernfehler = True
End Select
If curChecksumme < 0 Then
curChecksumme = 0 - curChecksumme
End If
If Trim(Mid(strZeile, 16, 18) / 100) <> Math.Round(curChecksumme, 2) Then
MsgBox("Checksumme: " & Trim(Mid(strZeile, 16, 18) / 100) & vbCrLf & "Prüfsumme: " & curChecksumme & vbCrLf & "Datei kann wegen Prüfsummenfehler nicht verarbeitet werden")
'Return False
End If
Loop
lngRecordCount = lngRecordCount + 1
Dim clfTrailer As New cUTA.UTATrailer(lngÜbertragungsnummer, dtmErstellDatumUhrzeit)
With clfTrailer
.ErstellDatumUhrzeit = dtmErstellDatumUhrzeit
.Übertragungsnummer = lngÜbertragungsnummer
.Anzahl_Sätze = Mid(strZeile, 3, 13)
.Checksumme = Mid(strZeile, 16, 18) / 100
.SAVE()
End With
Dim lngPKLine As Long = 0
lngRecordCount = 0
'gleicher PKFileName wird nun aus CLFHeader gelöscht. CASCADE löscht dann zugehörige CLFBody und CLFTrailer.
'If Not SQL.doSQL("DELETE tblUTAHeaderNew.ErstellDatumUhrzeit, tblUTAHeaderNew.Übertragungsnummer FROM tblUTAHeaderNew WHERE (((tblUTAHeaderNew.ErstellDatumUhrzeit)=" & Format$(dtmErstellDatumUhrzeit, "\#mm\/dd\/yyyy hh\:nn\:ss AM/PM\#") & ") AND ((tblUTAHeaderNew.Übertragungsnummer)=" & lngÜbertragungsnummer, "FMZOLL") Then
' MsgBox("Fehler beim Löschen des CLF-Headers")
' objFileRead.Close()
' Return False
'End If
'If Not SQL.doSQL("UPDATE CLF SET PKFileName = '" & fi.Name.ToString & "'", "FMZOLL") Then
' MsgBox("Fehler beim Update der CLF-Nr")
' objFileRead.Close()
' Return False
'End If
objFileRead.DiscardBufferedData()
objFileRead.BaseStream.Seek(0, System.IO.SeekOrigin.Begin)
Do While (objFileRead.Peek() > -1)
Dim strZeile = objFileRead.ReadLine()
Select Case Mid(strZeile, 1, 2)
Case "10"
booHeaderVorhanden = True
lngRecordCount = lngRecordCount + 1
dtmErstellDatumUhrzeit = DateSerial(Mid(strZeile, 35, 4), Mid(strZeile, 32, 2), Mid(strZeile, 29, 2)) & " " & TimeSerial(Mid(strZeile, 40, 2), Mid(strZeile, 43, 2), Mid(strZeile, 46, 2))
lngÜbertragungsnummer = Mid(strZeile, 61, 6)
'Dim ext = CInt(fi.Extension.Remove(0, 1))
Dim clfHeader As New cUTA.UTAHeader(lngÜbertragungsnummer, dtmErstellDatumUhrzeit)
With clfHeader
.Absender_ID = Mid(strZeile, 10, 6)
.Empfänger_ID = Mid(strZeile, 23, 6)
.Filler_Feld_5 = IIf(Trim(Mid(strZeile, 39, 1)) = "", Nothing, Trim(Mid(strZeile, 39, 1)))
.Abrechnungsnummer = IIf(Trim(Mid(strZeile, 48, 13)) = Nothing, "", Trim(Mid(strZeile, 48, 13)))
.DTF_Format = IIf(Trim(Mid(strZeile, 67, 6)) = Nothing, "", Trim(Mid(strZeile, 67, 6)))
.SAVE()
End With
Case "20"
'lngÜbertragungsposition = 6616
Case Else
' Andere RecordNumber überlesen.
End Select
lngRecordCount = lngRecordCount + 1
lngÜbertragungsposition = lngÜbertragungsposition + 1
Dim clfBody As New cUTA.UTABody(lngÜbertragungsnummer, lngÜbertragungsposition, dtmErstellDatumUhrzeit)
With clfBody
.Übertragungsnummer = lngÜbertragungsnummer
.Übertragungsposition = lngÜbertragungsposition
.Abrechnungsnummer = Mid(strZeile, 3, 13)
.[Datum_für_Lieferungen_und_Leistungen_bis] = DateSerial(Mid(strZeile, 20, 4), Mid(strZeile, 18, 2), Mid(strZeile, 16, 2))
.[Rechnungsempfänger_Kundennummer] = Mid(strZeile, 24, 13)
.[Abrechnungsdatum] = DateSerial(Mid(strZeile, 41, 4), Mid(strZeile, 39, 2), Mid(strZeile, 37, 2))
.[Kundennummer] = Mid(strZeile, 45, 13)
.[Kartennummer] = IIf(Trim(Mid(strZeile, 58, 19)) = "", Nothing, Trim(Mid(strZeile, 58, 19)))
.[Belegdatum] = DateSerial(Mid(strZeile, 81, 4), Mid(strZeile, 79, 2), Mid(strZeile, 77, 2))
.[Akzeptanzstellennummer] = Mid(strZeile, 85, 13)
.[Standort_der_Akzeptanzstelle] = IIf(Trim(Mid(strZeile, 98, 25)) = "", Nothing, Trim(Mid(strZeile, 98, 25)))
.[Lieferland] = IIf(Trim(Mid(strZeile, 123, 3)) = "", Nothing, Trim(Mid(strZeile, 123, 3)))
.[Belegnummer_des_Lieferanten] = IIf(Trim(Mid(strZeile, 126, 13)) = "", Nothing, Trim(Mid(strZeile, 126, 13)))
.[Kilometerstand] = Mid(strZeile, 139, 8)
.[Fakturierwarenart] = IIf(Trim(Mid(strZeile, 147, 5)) = "", Nothing, Trim(Mid(strZeile, 147, 5)))
.[Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen] = IIf(Trim(Mid(strZeile, 152, 1)) = "", Nothing, Trim(Mid(strZeile, 152, 1)))
.[Menge] = Mid(strZeile, 153, 10) / 100
.[SB_BT] = IIf(Trim(Mid(strZeile, 163, 1)) = "", Nothing, Trim(Mid(strZeile, 163, 1)))
.[Umsatzsteuerprozentsatz] = Mid(strZeile, 164, 5) / 10000
.[Lieferlandwährung_ISO] = IIf(Trim(Mid(strZeile, 169, 3)) = "", Nothing, Trim(Mid(strZeile, 169, 3)))
.[Einzelpreis_Brutto_in_Lieferlandwährung] = Mid(strZeile, 172, 11) / 100
.[Einzelpreis_Netto_in_Lieferlandwährung] = Mid(strZeile, 183, 11) / 100
.[Betrag_Service_in_Lieferlandwährung] = Mid(strZeile, 194, 11) / 100
.[Betrag_Nachlass_in_Lieferlandwährung] = Mid(strZeile, 205, 11) / 100
.[Gesamtbetrag_Netto_in_Lieferlandwährung] = Mid(strZeile, 216, 11) / 100
.[Gesamtbetrag_Brutto_in_Lieferlandwährung] = Mid(strZeile, 227, 11) / 100
.[Darstellwährung_ISO] = IIf(Trim(Mid(strZeile, 238, 3)) = "", Nothing, Trim(Mid(strZeile, 238, 3)))
.[Betrag_Service_in_Darstellwährung] = Mid(strZeile, 241, 11) / 100
.[Betrag_Nachlass_in_Darstellwährung] = Mid(strZeile, 252, 11) / 100
.[Gesamtbetrag_Netto_in_Darstellwährung] = Mid(strZeile, 263, 11) / 100
.[Gesamtbetrag_Umsatzsteuer_in_Darstellwährung] = Mid(strZeile, 274, 11) / 100
.[Gesamtbetrag_Brutto_in_Darstellwährung] = Mid(strZeile, 285, 11) / 100
.[Prägetext_i_d_R_KFZ_Kennzeichen] = IIf(Trim(Mid(strZeile, 296, 16)) = "", Nothing, Trim(Mid(strZeile, 296, 16)))
.[Kunden_Kostenstelle_1] = IIf(Trim(Mid(strZeile, 312, 20)) = "", Nothing, Trim(Mid(strZeile, 312, 20)))
.[Kartentyp] = IIf(Trim(Mid(strZeile, 332, 8)) = "", Nothing, Trim(Mid(strZeile, 332, 8)))
.[Filler_Feld_35] = IIf(Trim(Mid(strZeile, 340, 1)) = "", Nothing, Trim(Mid(strZeile, 340, 1)))
.[Filler_Feld_36] = IIf(Trim(Mid(strZeile, 341, 3)) = "", Nothing, Trim(Mid(strZeile, 341, 3)))
.[KZ_Autobahn] = IIf(Trim(Mid(strZeile, 344, 1)) = "", Nothing, Trim(Mid(strZeile, 344, 1)))
.[INFO_Feld] = IIf(Trim(Mid(strZeile, 345, 18)) = "", Nothing, Trim(Mid(strZeile, 345, 18)))
.[KFZ_Kennzeichen] = IIf(Trim(Mid(strZeile, 363, 16)) = "", Nothing, Trim(Mid(strZeile, 363, 16)))
.[Filler_Feld_40] = IIf(Trim(Mid(strZeile, 379, 1)) = "", Nothing, Trim(Mid(strZeile, 379, 1)))
.[Buchungsart] = IIf(Trim(Mid(strZeile, 380, 1)) = "", Nothing, Trim(Mid(strZeile, 380, 1)))
.[Buchungsgrund] = IIf(Trim(Mid(strZeile, 381, 1)) = "", Nothing, Trim(Mid(strZeile, 381, 1)))
.[Filler_Feld_43] = IIf(Trim(Mid(strZeile, 382, 1)) = "", Nothing, Trim(Mid(strZeile, 382, 1)))
.[Informationsbeleg] = IIf(Trim(Mid(strZeile, 383, 1)) = "", Nothing, Trim(Mid(strZeile, 383, 1)))
.[Belegherkunft] = IIf(Trim(Mid(strZeile, 384, 1)) = "", Nothing, Trim(Mid(strZeile, 384, 1)))
.[Filler_Feld_46] = IIf(Trim(Mid(strZeile, 385, 14)) = "", Nothing, Trim(Mid(strZeile, 385, 14)))
.[Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen] = Mid(strZeile, 399, 13) / 10000
.[Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen] = Mid(strZeile, 412, 13) / 10000
.[Rechnungsdatum] = DateSerial(Mid(strZeile, 429, 4), Mid(strZeile, 427, 2), Mid(strZeile, 425, 2))
.[Umsatzsteuerprozentsatz_informativ] = Mid(strZeile, 433, 5) / 10000
.[Betrag_Nachlass_in_Lieferlandwährung_Umsatzsteuer_informativ] = Mid(strZeile, 438, 11) / 100
.[Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ] = Mid(strZeile, 449, 11) / 100
.[Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ] = Mid(strZeile, 460, 11) / 100
.[Fälligkeitsdatum] = DateSerial(Mid(strZeile, 475, 4), Mid(strZeile, 473, 2), Mid(strZeile, 471, 2))
.[Zahlungsziel_in_Tagen] = Mid(strZeile, 479, 3)
.[Zahlungsart] = IIf(Trim(Mid(strZeile, 482, 8)) = "", Nothing, Trim(Mid(strZeile, 482, 8)))
.[TC_Rechnungsnummer_gegenüber_dem_Nutzer] = IIf(Trim(Mid(strZeile, 490, 20)) = "", Nothing, Trim(Mid(strZeile, 490, 20)))
.[TC_Rechnungsdatum] = DateSerial(Mid(strZeile, 514, 4), Mid(strZeile, 512, 2), Mid(strZeile, 510, 2))
.[Zahlungszielgruppe] = IIf(Trim(Mid(strZeile, 518, 7)) = "", Nothing, Trim(Mid(strZeile, 518, 7)))
.[Kunden_Kostenstelle_2] = IIf(Trim(Mid(strZeile, 525, 20)) = "", Nothing, Trim(Mid(strZeile, 525, 20)))
.[Lieferzeit] = IIf(Trim(Mid(strZeile, 545, 6)) = "", Nothing, Trim(Mid(strZeile, 545, 6)))
.[Fremdkartennummer] = IIf(Trim(Mid(strZeile, 551, 20)) = "", Nothing, Trim(Mid(strZeile, 551, 20)))
.[OnBoardUnitID] = IIf(Trim(Mid(strZeile, 571, 20)) = "", Nothing, Trim(Mid(strZeile, 571, 20)))
.[KFZ_Kennzeichen_komprimiert] = IIf(Trim(Mid(strZeile, 591, 16)) = "", Nothing, Trim(Mid(strZeile, 591, 16)))
.[Kartenkategorie] = IIf(Trim(Mid(strZeile, 607, 8)) = "", Nothing, Trim(Mid(strZeile, 607, 8)))
.[Rechnungsnummer_pro_Lieferland] = Mid(strZeile, 615, 13)
.[Autobahnauffahrt] = IIf(Trim(Mid(strZeile, 628, 40)) = "", Nothing, Trim(Mid(strZeile, 628, 40)))
.[Autobahnausfahrt] = IIf(Trim(Mid(strZeile, 668, 40)) = "", Nothing, Trim(Mid(strZeile, 668, 40)))
.[Rabattschlüssel_der_französischen_Autobahngesellschaften] = IIf(Trim(Mid(strZeile, 708, 1)) = "", Nothing, Trim(Mid(strZeile, 708, 1)))
.[Nummer_Belastungsanzeige] = Mid(strZeile, 709, 13)
.[Betreuungsstelle] = IIf(Trim(Mid(strZeile, 722, 20)) = "", Nothing, Trim(Mid(strZeile, 722, 20)))
.[Filler_Feld_72] = IIf(Trim(Mid(strZeile, 742, 20)) = "", Nothing, Trim(Mid(strZeile, 742, 20)))
.[Akzeptanz_Medium] = IIf(Trim(Mid(strZeile, 762, 20)) = "", Nothing, Trim(Mid(strZeile, 762, 20)))
.[Steuerkategorie] = IIf(Trim(Mid(strZeile, 782, 8)) = "", Nothing, Trim(Mid(strZeile, 782, 8)))
.[UTA_Beleg_ID] = Mid(strZeile, 790, 11)
.[UTA_Normalbeleg_ID] = Mid(strZeile, 801, 11)
.[Gebühren_Bescheinigung_von] = DateSerial(Mid(strZeile, 816, 4), Mid(strZeile, 814, 2), Mid(strZeile, 812, 2))
.[Gebühren_Bescheinigung_bis] = DateSerial(Mid(strZeile, 824, 4), Mid(strZeile, 822, 2), Mid(strZeile, 820, 2))
.[Herausgeber_Nutzer_Nummer] = IIf(Trim(Mid(strZeile, 828, 20)) = "", Nothing, Trim(Mid(strZeile, 828, 20)))
.[Maßeinheit] = IIf(Trim(Mid(strZeile, 848, 8)) = "", Nothing, Trim(Mid(strZeile, 848, 8)))
.[Land_der_Akzeptanzstelle] = IIf(Trim(Mid(strZeile, 856, 3)) = "", Nothing, Trim(Mid(strZeile, 856, 3)))
.[Postleitzahl_der_Akzeptanzstelle] = IIf(Trim(Mid(strZeile, 859, 7)) = "", Nothing, Trim(Mid(strZeile, 859, 7)))
.[Steuerliches_Lieferland] = IIf(Trim(Mid(strZeile, 866, 3)) = "", Nothing, Trim(Mid(strZeile, 866, 3)))
.[Steuerliche_Produktgruppe] = IIf(Trim(Mid(strZeile, 869, 5)) = "", Nothing, Trim(Mid(strZeile, 869, 5)))
.[Leistungsort_verlagerbar] = IIf(Trim(Mid(strZeile, 874, 1)) = "", Nothing, Trim(Mid(strZeile, 874, 1)))
Loop
Select Case .[Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen]
Case "0" 'positiv
curChecksumme = curChecksumme + .[Gesamtbetrag_Brutto_in_Darstellwährung]
Case "1" 'negativ
curChecksumme = curChecksumme - .[Gesamtbetrag_Brutto_in_Darstellwährung]
.[Menge] = 0 - .[Menge]
.[Einzelpreis_Brutto_in_Lieferlandwährung] = 0 - .[Einzelpreis_Brutto_in_Lieferlandwährung]
.[Einzelpreis_Netto_in_Lieferlandwährung] = 0 - .[Einzelpreis_Netto_in_Lieferlandwährung]
.[Betrag_Service_in_Lieferlandwährung] = 0 - .[Betrag_Service_in_Lieferlandwährung]
.[Betrag_Nachlass_in_Lieferlandwährung] = 0 - .[Betrag_Nachlass_in_Lieferlandwährung]
.[Gesamtbetrag_Netto_in_Lieferlandwährung] = 0 - .[Gesamtbetrag_Netto_in_Lieferlandwährung]
.[Gesamtbetrag_Brutto_in_Lieferlandwährung] = 0 - .[Gesamtbetrag_Brutto_in_Lieferlandwährung]
.[Betrag_Service_in_Darstellwährung] = 0 - .[Betrag_Service_in_Darstellwährung]
.[Betrag_Nachlass_in_Darstellwährung] = 0 - .[Betrag_Nachlass_in_Darstellwährung]
.[Gesamtbetrag_Netto_in_Darstellwährung] = 0 - .[Gesamtbetrag_Netto_in_Darstellwährung]
.[Gesamtbetrag_Umsatzsteuer_in_Darstellwährung] = 0 - .[Gesamtbetrag_Umsatzsteuer_in_Darstellwährung]
.[Gesamtbetrag_Brutto_in_Darstellwährung] = 0 - .[Gesamtbetrag_Brutto_in_Darstellwährung]
.[Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen] = 0 - .[Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen]
.[Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen] = 0 - .[Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen]
.[Betrag_Nachlass_in_Lieferlandwährung_Umsatzsteuer_informativ] = 0 - .[Betrag_Nachlass_in_Lieferlandwährung_Umsatzsteuer_informativ]
.[Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ] = 0 - .[Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ]
.[Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ] = 0 - .[Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ]
End Select
If onlyTestkunedn Then
'nur KundenNr 100964 und 825040 speichern:
If .[Kundennummer] = 100964 Or .[Kundennummer] = 825040 Then
.SAVE()
End If
Else
.SAVE()
End If
'Dim clfArchiv As New cUTA.UTAArchiv(.Belegdatum, .UTA_Beleg_ID)
'clfArchiv.Übertragungsnummer = .Übertragungsnummer
'clfArchiv.ErstellDatumUhrzeit = .ErstellDatumUhrzeit
'clfArchiv.Übertragungsposition = .Übertragungsposition
'clfArchiv.Abrechnungsnummer = .Abrechnungsnummer
'clfArchiv.Datum_für_Lieferungen_und_Leistungen_bis = .Datum_für_Lieferungen_und_Leistungen_bis
'clfArchiv.Rechnungsempfänger_Kundennummer = .Rechnungsempfänger_Kundennummer
'clfArchiv.Abrechnungsdatum = .Abrechnungsdatum
'clfArchiv.Kundennummer = .Kundennummer
'clfArchiv.Kartennummer = .Kartennummer
'clfArchiv.Akzeptanzstellennummer = .Akzeptanzstellennummer
'clfArchiv.Standort_der_Akzeptanzstelle = .Standort_der_Akzeptanzstelle
'clfArchiv.Lieferland = .Lieferland
'clfArchiv.Belegnummer_des_Lieferanten = .Belegnummer_des_Lieferanten
'clfArchiv.Kilometerstand = .Kilometerstand
'clfArchiv.Fakturierwarenart = .Fakturierwarenart
'clfArchiv.Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen = .Vorzeichen_Statusfeld_für_alle_Beträge_und_Mengen
'clfArchiv.Menge = .Menge
'clfArchiv.SB_BT = .SB_BT
'clfArchiv.Umsatzsteuerprozentsatz = .Umsatzsteuerprozentsatz
'clfArchiv.Lieferlandwährung_ISO = .Lieferlandwährung_ISO
'clfArchiv.Einzelpreis_Netto_in_Lieferlandwährung = .Einzelpreis_Netto_in_Lieferlandwährung
'clfArchiv.Einzelpreis_Brutto_in_Lieferlandwährung = .Einzelpreis_Brutto_in_Lieferlandwährung
'clfArchiv.Einzelpreis_Netto_in_Lieferlandwährung = .Einzelpreis_Netto_in_Lieferlandwährung
'clfArchiv.Betrag_Service_in_Lieferlandwährung = .Betrag_Service_in_Lieferlandwährung
'clfArchiv.Betrag_Nachlass_in_Lieferlandwährung = .Betrag_Nachlass_in_Lieferlandwährung
'clfArchiv.Gesamtbetrag_Netto_in_Lieferlandwährung = .Gesamtbetrag_Netto_in_Lieferlandwährung
'clfArchiv.Gesamtbetrag_Brutto_in_Lieferlandwährung = .Gesamtbetrag_Brutto_in_Lieferlandwährung
'clfArchiv.Darstellwährung_ISO = .Darstellwährung_ISO
'clfArchiv.Betrag_Service_in_Darstellwährung = .Betrag_Service_in_Darstellwährung
'clfArchiv.Betrag_Nachlass_in_Darstellwährung = .Betrag_Nachlass_in_Darstellwährung
'clfArchiv.Gesamtbetrag_Netto_in_Darstellwährung = .Gesamtbetrag_Netto_in_Darstellwährung
'clfArchiv.Gesamtbetrag_Umsatzsteuer_in_Darstellwährung = .Gesamtbetrag_Umsatzsteuer_in_Darstellwährung
'clfArchiv.Gesamtbetrag_Brutto_in_Darstellwährung = .Gesamtbetrag_Brutto_in_Darstellwährung
'clfArchiv.Prägetext_i_d_R_KFZ_Kennzeichen = .Prägetext_i_d_R_KFZ_Kennzeichen
'clfArchiv.Kunden_Kostenstelle_1 = .Kunden_Kostenstelle_1
'clfArchiv.Kartentyp = .Kartentyp
'clfArchiv.Filler_Feld_35 = .Filler_Feld_35
'clfArchiv.Filler_Feld_36 = .Filler_Feld_36
'clfArchiv.KZ_Autobahn = .KZ_Autobahn
'clfArchiv.INFO_Feld = .INFO_Feld
'clfArchiv.KFZ_Kennzeichen = .KFZ_Kennzeichen
'clfArchiv.Filler_Feld_40 = .Filler_Feld_40
'clfArchiv.Buchungsart = .Buchungsart
'clfArchiv.Buchungsgrund = .Buchungsgrund
'clfArchiv.Filler_Feld_43 = .Filler_Feld_43
'clfArchiv.Informationsbeleg = .Informationsbeleg
'clfArchiv.Belegherkunft = .Belegherkunft
'clfArchiv.Filler_Feld_46 = .Filler_Feld_46
'clfArchiv.Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen = .Einzelpreis_Brutto_in_Lieferlandwährung_mit_4_Nachkommastellen
'clfArchiv.Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen = .Einzelpreis_Netto_in_Lieferlandwährung_mit_4_Nachkommastellen
'clfArchiv.Rechnungsdatum = .Rechnungsdatum
'clfArchiv.Umsatzsteuerprozentsatz_informativ = .Umsatzsteuerprozentsatz_informativ
'clfArchiv.Betrag_Nachlass_in_Lieferlandwährung = .Betrag_Nachlass_in_Lieferlandwährung
'clfArchiv.Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ = .Betrag_Service_in_Lieferlandwährung_Umsatzsteuer_informativ
'clfArchiv.Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ = .Gesamtbetrag_in_Lieferlandwährung_Umsatzsteuer_informativ
'clfArchiv.Fälligkeitsdatum = .Fälligkeitsdatum
'clfArchiv.Zahlungsziel_in_Tagen = .Zahlungsziel_in_Tagen
'clfArchiv.Zahlungsart = .Zahlungsart
'clfArchiv.TC_Rechnungsnummer_gegenüber_dem_Nutzer = .TC_Rechnungsnummer_gegenüber_dem_Nutzer
'clfArchiv.TC_Rechnungsdatum = .TC_Rechnungsdatum
'clfArchiv.Zahlungszielgruppe = .Zahlungszielgruppe
'clfArchiv.Kunden_Kostenstelle_2 = .Kunden_Kostenstelle_2
'clfArchiv.Lieferzeit = .Lieferzeit
'clfArchiv.Fremdkartennummer = .Fremdkartennummer
'clfArchiv.OnBoardUnitID = .OnBoardUnitID
'clfArchiv.KFZ_Kennzeichen_komprimiert = .KFZ_Kennzeichen_komprimiert
'clfArchiv.Kartenkategorie = .Kartenkategorie
'clfArchiv.Rechnungsnummer_pro_Lieferland = .Rechnungsnummer_pro_Lieferland
'clfArchiv.Autobahnauffahrt = .Autobahnauffahrt
'clfArchiv.Autobahnausfahrt = .Autobahnausfahrt
'clfArchiv.Rabattschlüssel_der_französischen_Autobahngesellschaften = .Rabattschlüssel_der_französischen_Autobahngesellschaften
'clfArchiv.Nummer_Belastungsanzeige = .Nummer_Belastungsanzeige
'clfArchiv.Betreuungsstelle = .Betreuungsstelle
'clfArchiv.Filler_Feld_72 = .Filler_Feld_72
'clfArchiv.Akzeptanz_Medium = .Akzeptanz_Medium
'clfArchiv.Steuerkategorie = .Steuerkategorie
'clfArchiv.UTA_Normalbeleg_ID = .UTA_Normalbeleg_ID
'clfArchiv.Gebühren_Bescheinigung_von = .Gebühren_Bescheinigung_von
'clfArchiv.Gebühren_Bescheinigung_bis = .Gebühren_Bescheinigung_bis
'clfArchiv.Herausgeber_Nutzer_Nummer = .Herausgeber_Nutzer_Nummer
'clfArchiv.Maßeinheit = .Maßeinheit
'clfArchiv.Land_der_Akzeptanzstelle = .Land_der_Akzeptanzstelle
'clfArchiv.Postleitzahl_der_Akzeptanzstelle = .Postleitzahl_der_Akzeptanzstelle
'clfArchiv.Steuerliches_Lieferland = .Steuerliches_Lieferland
'clfArchiv.Steuerliche_Produktgruppe = .Steuerliche_Produktgruppe
'clfArchiv.Leistungsort_verlagerbar = .Leistungsort_verlagerbar
'clfArchiv.SAVE()
End With
Case "90"
If curChecksumme < 0 Then
curChecksumme = 0 - curChecksumme
End If
If Trim(Mid(strZeile, 16, 18) / 100) <> Math.Round(curChecksumme, 2) Then
MsgBox("Checksumme: " & Trim(Mid(strZeile, 16, 18) / 100) & vbCrLf & "Prüfsumme: " & curChecksumme & vbCrLf & "Datei kann wegen Prüfsummenfehler nicht verarbeitet werden")
'Return False
End If
lngRecordCount = lngRecordCount + 1
Dim clfTrailer As New cUTA.UTATrailer(lngÜbertragungsnummer, dtmErstellDatumUhrzeit)
With clfTrailer
.ErstellDatumUhrzeit = dtmErstellDatumUhrzeit
.Übertragungsnummer = lngÜbertragungsnummer
.Anzahl_Sätze = Mid(strZeile, 3, 13)
.Checksumme = Mid(strZeile, 16, 18) / 100
.SAVE()
End With
Case Else
' Andere RecordNumber überlesen.
End Select
Loop
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace & vbNewLine & "Datei: " & Dateiname, System.Reflection.MethodInfo.GetCurrentMethod.Name)
End Try
cnt = CInt(lngRecordCount)
objFileRead.Close()
Return True
@@ -1380,7 +1391,7 @@ Public Class cUTA
End Function
Public Shared Function UPDATE_ARCHIV(reDat As Date, reNr As Integer, uta_kdNr As Integer, ustvaId As Integer) As Boolean
Public Shared Function UPDATE_ARCHIV(reDat As Date, reNr As String, uta_kdNr As String, ustvaId As Integer) As Boolean
Try
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL

View File

@@ -1365,8 +1365,9 @@ Public Class cFormularManager
If VERAG_PROG_ALLGEMEIN.cAllgemein.PRINTER_STANDARD <> String.Empty Then
For i As Integer = 0 To sPrinters.Count - 1
If i.ToString.ToLower.Contains(VERAG_PROG_ALLGEMEIN.cAllgemein.PRINTER_STANDARD.ToLower) Then
printerName = i
Dim printer As String = sPrinters(i).ToString.ToLower
If printer.Contains(VERAG_PROG_ALLGEMEIN.cAllgemein.PRINTER_STANDARD.ToLower) Then
printerName = printer
End If
Next
End If

View File

@@ -28,7 +28,6 @@ Partial Class frmMitarbeitersuche
Me.Button4 = New System.Windows.Forms.Button()
Me.btnClose = New System.Windows.Forms.Button()
Me.PictureBox2 = New System.Windows.Forms.PictureBox()
Me.sbMitarbeiter = New VERAG_PROG_ALLGEMEIN.MySearchBox()
Me.pnlMain = New System.Windows.Forms.Panel()
Me.pnl = New System.Windows.Forms.Panel()
Me.Button3 = New System.Windows.Forms.Button()
@@ -73,6 +72,7 @@ Partial Class frmMitarbeitersuche
Me.pnlGeburtstag = New System.Windows.Forms.Panel()
Me.lblGeburtstag = New System.Windows.Forms.Label()
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components)
Me.Panel1 = New System.Windows.Forms.Panel()
Me.lblPosition = New System.Windows.Forms.Label()
@@ -83,7 +83,12 @@ Partial Class frmMitarbeitersuche
Me.lblFirma = New System.Windows.Forms.Label()
Me.Label4 = New System.Windows.Forms.Label()
Me.Label3 = New System.Windows.Forms.Label()
Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.pnlNotfallkontakt = New System.Windows.Forms.Panel()
Me.lblNotfall_Mail = New System.Windows.Forms.Label()
Me.Label17 = New System.Windows.Forms.Label()
Me.lblNotfall_Handy = New System.Windows.Forms.Label()
Me.lblNotfall_Name = New System.Windows.Forms.Label()
Me.sbMitarbeiter = New VERAG_PROG_ALLGEMEIN.MySearchBox()
Me.pnlSrch.SuspendLayout()
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).BeginInit()
Me.pnlMain.SuspendLayout()
@@ -99,6 +104,7 @@ Partial Class frmMitarbeitersuche
Me.pnlGeburtstag.SuspendLayout()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
Me.MyPanel1.SuspendLayout()
Me.pnlNotfallkontakt.SuspendLayout()
Me.SuspendLayout()
'
'pnlSrch
@@ -156,32 +162,6 @@ Partial Class frmMitarbeitersuche
Me.PictureBox2.TabIndex = 18
Me.PictureBox2.TabStop = False
'
'sbMitarbeiter
'
Me.sbMitarbeiter._allowFreitext = False
Me.sbMitarbeiter._AllowSetValue = False
Me.sbMitarbeiter._allowSpaceAsSplitter = True
Me.sbMitarbeiter._autoSizeGross = False
Me.sbMitarbeiter._hideIfListEmpty = True
Me.sbMitarbeiter._value = Nothing
Me.sbMitarbeiter.conn_art = "FMZOLL"
Me.sbMitarbeiter.dgvpos = "LEFT"
Me.sbMitarbeiter.DISPLAY_PARAM = Nothing
Me.sbMitarbeiter.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.sbMitarbeiter.INVISIBLE_COLUMNS = Nothing
Me.sbMitarbeiter.key_visible = False
Me.sbMitarbeiter.KEYPARAM = Nothing
Me.sbMitarbeiter.Location = New System.Drawing.Point(45, 11)
Me.sbMitarbeiter.Name = "sbMitarbeiter"
Me.sbMitarbeiter.searchActive = True
Me.sbMitarbeiter.Size = New System.Drawing.Size(582, 29)
Me.sbMitarbeiter.SQL_ORDER_BY = Nothing
Me.sbMitarbeiter.SQL_SELECT = Nothing
Me.sbMitarbeiter.SQL_WHERE = Nothing
Me.sbMitarbeiter.SQL_WhereParamList = Nothing
Me.sbMitarbeiter.TabIndex = 0
Me.sbMitarbeiter.usrcntl = Nothing
'
'pnlMain
'
Me.pnlMain.AutoSizeMode = System.Windows.Forms.AutoSizeMode.GrowAndShrink
@@ -704,6 +684,11 @@ Partial Class frmMitarbeitersuche
Me.PictureBox1.TabIndex = 13
Me.PictureBox1.TabStop = False
'
'ContextMenuStrip1
'
Me.ContextMenuStrip1.Name = "ContextMenuStrip1"
Me.ContextMenuStrip1.Size = New System.Drawing.Size(61, 4)
'
'MyPanel1
'
Me.MyPanel1.BackColor = System.Drawing.Color.FromArgb(CType(CType(250, Byte), Integer), CType(CType(254, Byte), Integer), CType(CType(255, Byte), Integer))
@@ -716,6 +701,7 @@ Partial Class frmMitarbeitersuche
Me.MyPanel1.Controls.Add(Me.lblFirma)
Me.MyPanel1.Controls.Add(Me.Label4)
Me.MyPanel1.Controls.Add(Me.Label3)
Me.MyPanel1.Controls.Add(Me.pnlNotfallkontakt)
Me.MyPanel1.Location = New System.Drawing.Point(197, 188)
Me.MyPanel1.Name = "MyPanel1"
Me.MyPanel1.Size = New System.Drawing.Size(578, 109)
@@ -735,7 +721,7 @@ Partial Class frmMitarbeitersuche
Me.lblPosition.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
Me.lblPosition.Location = New System.Drawing.Point(158, 80)
Me.lblPosition.Name = "lblPosition"
Me.lblPosition.Size = New System.Drawing.Size(411, 25)
Me.lblPosition.Size = New System.Drawing.Size(209, 25)
Me.lblPosition.TabIndex = 10
Me.lblPosition.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
@@ -768,7 +754,7 @@ Partial Class frmMitarbeitersuche
Me.lblAbteilung.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
Me.lblAbteilung.Location = New System.Drawing.Point(158, 55)
Me.lblAbteilung.Name = "lblAbteilung"
Me.lblAbteilung.Size = New System.Drawing.Size(411, 25)
Me.lblAbteilung.Size = New System.Drawing.Size(209, 25)
Me.lblAbteilung.TabIndex = 8
Me.lblAbteilung.Text = "IT"
Me.lblAbteilung.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
@@ -779,7 +765,7 @@ Partial Class frmMitarbeitersuche
Me.lblNiederlassung.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
Me.lblNiederlassung.Location = New System.Drawing.Point(158, 30)
Me.lblNiederlassung.Name = "lblNiederlassung"
Me.lblNiederlassung.Size = New System.Drawing.Size(411, 25)
Me.lblNiederlassung.Size = New System.Drawing.Size(209, 25)
Me.lblNiederlassung.TabIndex = 7
Me.lblNiederlassung.Text = "SUBEN"
Me.lblNiederlassung.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
@@ -790,7 +776,7 @@ Partial Class frmMitarbeitersuche
Me.lblFirma.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold)
Me.lblFirma.Location = New System.Drawing.Point(158, 5)
Me.lblFirma.Name = "lblFirma"
Me.lblFirma.Size = New System.Drawing.Size(411, 25)
Me.lblFirma.Size = New System.Drawing.Size(209, 25)
Me.lblFirma.TabIndex = 6
Me.lblFirma.Text = "VERAG"
Me.lblFirma.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
@@ -817,10 +803,88 @@ Partial Class frmMitarbeitersuche
Me.Label3.Text = "Niederlassung:"
Me.Label3.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'ContextMenuStrip1
'pnlNotfallkontakt
'
Me.ContextMenuStrip1.Name = "ContextMenuStrip1"
Me.ContextMenuStrip1.Size = New System.Drawing.Size(61, 4)
Me.pnlNotfallkontakt.BackColor = System.Drawing.Color.FromArgb(CType(CType(255, Byte), Integer), CType(CType(255, Byte), Integer), CType(CType(192, Byte), Integer))
Me.pnlNotfallkontakt.Controls.Add(Me.lblNotfall_Mail)
Me.pnlNotfallkontakt.Controls.Add(Me.Label17)
Me.pnlNotfallkontakt.Controls.Add(Me.lblNotfall_Handy)
Me.pnlNotfallkontakt.Controls.Add(Me.lblNotfall_Name)
Me.pnlNotfallkontakt.Location = New System.Drawing.Point(374, 5)
Me.pnlNotfallkontakt.Name = "pnlNotfallkontakt"
Me.pnlNotfallkontakt.Size = New System.Drawing.Size(200, 100)
Me.pnlNotfallkontakt.TabIndex = 49
Me.pnlNotfallkontakt.Visible = False
'
'lblNotfall_Mail
'
Me.lblNotfall_Mail.BackColor = System.Drawing.Color.Transparent
Me.lblNotfall_Mail.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Bold)
Me.lblNotfall_Mail.Location = New System.Drawing.Point(-1, 75)
Me.lblNotfall_Mail.Name = "lblNotfall_Mail"
Me.lblNotfall_Mail.Size = New System.Drawing.Size(202, 25)
Me.lblNotfall_Mail.TabIndex = 48
Me.lblNotfall_Mail.Text = "-"
Me.lblNotfall_Mail.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'Label17
'
Me.Label17.AutoSize = True
Me.Label17.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!, CType((System.Drawing.FontStyle.Bold Or System.Drawing.FontStyle.Underline), System.Drawing.FontStyle))
Me.Label17.Location = New System.Drawing.Point(-4, 1)
Me.Label17.Name = "Label17"
Me.Label17.Size = New System.Drawing.Size(139, 24)
Me.Label17.TabIndex = 45
Me.Label17.Text = "Notfallkontakt:"
Me.Label17.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'lblNotfall_Handy
'
Me.lblNotfall_Handy.BackColor = System.Drawing.Color.Transparent
Me.lblNotfall_Handy.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Bold)
Me.lblNotfall_Handy.Location = New System.Drawing.Point(-1, 50)
Me.lblNotfall_Handy.Name = "lblNotfall_Handy"
Me.lblNotfall_Handy.Size = New System.Drawing.Size(202, 25)
Me.lblNotfall_Handy.TabIndex = 47
Me.lblNotfall_Handy.Text = "-"
Me.lblNotfall_Handy.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'lblNotfall_Name
'
Me.lblNotfall_Name.BackColor = System.Drawing.Color.Transparent
Me.lblNotfall_Name.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Bold)
Me.lblNotfall_Name.Location = New System.Drawing.Point(-1, 25)
Me.lblNotfall_Name.Name = "lblNotfall_Name"
Me.lblNotfall_Name.Size = New System.Drawing.Size(202, 25)
Me.lblNotfall_Name.TabIndex = 46
Me.lblNotfall_Name.Text = "-"
Me.lblNotfall_Name.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'sbMitarbeiter
'
Me.sbMitarbeiter._allowFreitext = False
Me.sbMitarbeiter._AllowSetValue = False
Me.sbMitarbeiter._allowSpaceAsSplitter = True
Me.sbMitarbeiter._autoSizeGross = False
Me.sbMitarbeiter._hideIfListEmpty = True
Me.sbMitarbeiter._value = Nothing
Me.sbMitarbeiter.conn_art = "FMZOLL"
Me.sbMitarbeiter.dgvpos = "LEFT"
Me.sbMitarbeiter.DISPLAY_PARAM = Nothing
Me.sbMitarbeiter.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.sbMitarbeiter.INVISIBLE_COLUMNS = Nothing
Me.sbMitarbeiter.key_visible = False
Me.sbMitarbeiter.KEYPARAM = Nothing
Me.sbMitarbeiter.Location = New System.Drawing.Point(45, 11)
Me.sbMitarbeiter.Name = "sbMitarbeiter"
Me.sbMitarbeiter.searchActive = True
Me.sbMitarbeiter.Size = New System.Drawing.Size(582, 29)
Me.sbMitarbeiter.SQL_ORDER_BY = Nothing
Me.sbMitarbeiter.SQL_SELECT = Nothing
Me.sbMitarbeiter.SQL_WHERE = Nothing
Me.sbMitarbeiter.SQL_WhereParamList = Nothing
Me.sbMitarbeiter.TabIndex = 0
Me.sbMitarbeiter.usrcntl = Nothing
'
'frmMitarbeitersuche
'
@@ -856,6 +920,8 @@ Partial Class frmMitarbeitersuche
Me.pnlGeburtstag.PerformLayout()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
Me.MyPanel1.ResumeLayout(False)
Me.pnlNotfallkontakt.ResumeLayout(False)
Me.pnlNotfallkontakt.PerformLayout()
Me.ResumeLayout(False)
End Sub
@@ -920,4 +986,9 @@ Partial Class frmMitarbeitersuche
Friend WithEvents btnAkten As Windows.Forms.Button
Friend WithEvents Button3 As Windows.Forms.Button
Friend WithEvents ContextMenuStrip1 As Windows.Forms.ContextMenuStrip
Friend WithEvents pnlNotfallkontakt As Windows.Forms.Panel
Friend WithEvents lblNotfall_Mail As Windows.Forms.Label
Friend WithEvents Label17 As Windows.Forms.Label
Friend WithEvents lblNotfall_Handy As Windows.Forms.Label
Friend WithEvents lblNotfall_Name As Windows.Forms.Label
End Class

View File

@@ -100,6 +100,11 @@ Public Class frmMitarbeitersuche
pnlWohnadresse.Visible = MA.mit_MAVerzeichnis_allowWohnadresse
lblNotfall_Name.Text = If(MA.mit_Notfall_Name, "")
lblNotfall_Handy.Text = If(MA.mit_Notfall_Handy, "")
lblNotfall_Mail.Text = If(MA.mit_Notfall_Mail, "")
lblMotto.Text = MA.mit_MAVerzeichnis_Motto
If lblMotto.Text.Trim <> "" Then lblMotto.Text = """" & lblMotto.Text & """"
pnlMotto.Visible = (lblMotto.Text <> "")
@@ -169,10 +174,11 @@ Public Class frmMitarbeitersuche
'requestDone = Not callTimasSaldo
initTimasData()
pnlNotfallkontakt.Visible = False
If VERAG_PROG_ALLGEMEIN.cAllgemein.USRID = MA.mit_id Then
btnEdit.Visible = True
pnlNotfallkontakt.Visible = True
If VERAG_PROG_ALLGEMEIN.cAllgemein.MITARBEITER.mit_timasId IsNot Nothing Then
pnlZeiten.Visible = True
Else
@@ -186,11 +192,15 @@ Public Class frmMitarbeitersuche
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("ADMINFUNCTIONS", "SDL") Then
btnEdit.Visible = True
btnSettings.Visible = True
pnlNotfallkontakt.Visible = True
End If
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("MA_TeamBearbeiten", "SDL") Then
If MA.getFirma = VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA Then 'MA derselben Firma bearbeiten
btnSettings.Visible = True
pnlNotfallkontakt.Visible = True
End If
End If
@@ -230,6 +240,12 @@ Public Class frmMitarbeitersuche
pic.BackgroundImage = My.Resources.personGray_m
picGeschlecht.Visible = False
pnlZeiten.Visible = False
lblNotfall_Name.Text = ""
lblNotfall_Handy.Text = ""
lblNotfall_Mail.Text = ""
End Sub
Private Sub btnClose_Click(sender As Object, e As EventArgs) Handles btnClose.Click
@@ -237,15 +253,19 @@ Public Class frmMitarbeitersuche
End Sub
Private Sub btn_Click(sender As Object, e As EventArgs) Handles btnEdit.Click
If sbMitarbeiter._value = "" Then Exit Sub
Dim f As New frmMitarbeitersucheBearbeiten(sbMitarbeiter._value)
f.ShowDialog(Me)
initMA()
End Sub
Private Sub frmMitarbeitersuche_Shown(sender As Object, e As EventArgs) Handles Me.Shown
If mit_id > 0 Then
sbMitarbeiter.SET_VALUE(mit_id)
sbMitarbeiter._value = mit_id
initMA()
End If
End Sub

View File

@@ -26,9 +26,14 @@ Partial Class frmMitarbeitersucheBearbeiten
Me.pnlSrch = New System.Windows.Forms.Panel()
Me.btnClose = New System.Windows.Forms.Button()
Me.pnlMain = New System.Windows.Forms.Panel()
Me.pnlHoverPic = New System.Windows.Forms.Panel()
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
Me.PictureBox2 = New System.Windows.Forms.PictureBox()
Me.txtKonfigHinweis = New System.Windows.Forms.TextBox()
Me.Label1 = New System.Windows.Forms.Label()
Me.cbxAllowFoto = New System.Windows.Forms.CheckBox()
Me.btn = New System.Windows.Forms.Button()
Me.txtMotto = New System.Windows.Forms.TextBox()
Me.txtNotfall_Name = New System.Windows.Forms.TextBox()
Me.cbxMotto = New System.Windows.Forms.CheckBox()
Me.cbxGeburtsdatumOhneJahr = New System.Windows.Forms.CheckBox()
Me.txtHandynummer = New System.Windows.Forms.TextBox()
@@ -41,17 +46,20 @@ Partial Class frmMitarbeitersucheBearbeiten
Me.lblWohnadresse = New System.Windows.Forms.Label()
Me.lblName = New System.Windows.Forms.Label()
Me.pic = New System.Windows.Forms.PictureBox()
Me.pnlHoverPic = New System.Windows.Forms.Panel()
Me.Label1 = New System.Windows.Forms.Label()
Me.PictureBox2 = New System.Windows.Forms.PictureBox()
Me.PictureBox1 = New System.Windows.Forms.PictureBox()
Me.txtKonfigHinweis = New System.Windows.Forms.TextBox()
Me.Label2 = New System.Windows.Forms.Label()
Me.Label3 = New System.Windows.Forms.Label()
Me.Label4 = New System.Windows.Forms.Label()
Me.txtNotfall_Handy = New System.Windows.Forms.TextBox()
Me.Label5 = New System.Windows.Forms.Label()
Me.txtNotfall_Mail = New System.Windows.Forms.TextBox()
Me.Label6 = New System.Windows.Forms.Label()
Me.txtMotto = New System.Windows.Forms.TextBox()
Me.pnlSrch.SuspendLayout()
Me.pnlMain.SuspendLayout()
CType(Me.pic, System.ComponentModel.ISupportInitialize).BeginInit()
Me.pnlHoverPic.SuspendLayout()
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.pic, System.ComponentModel.ISupportInitialize).BeginInit()
Me.SuspendLayout()
'
'pnlSrch
@@ -85,10 +93,18 @@ Partial Class frmMitarbeitersucheBearbeiten
'pnlMain
'
Me.pnlMain.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle
Me.pnlMain.Controls.Add(Me.txtMotto)
Me.pnlMain.Controls.Add(Me.Label6)
Me.pnlMain.Controls.Add(Me.Label5)
Me.pnlMain.Controls.Add(Me.txtNotfall_Mail)
Me.pnlMain.Controls.Add(Me.Label4)
Me.pnlMain.Controls.Add(Me.txtNotfall_Handy)
Me.pnlMain.Controls.Add(Me.Label3)
Me.pnlMain.Controls.Add(Me.Label2)
Me.pnlMain.Controls.Add(Me.pnlHoverPic)
Me.pnlMain.Controls.Add(Me.cbxAllowFoto)
Me.pnlMain.Controls.Add(Me.btn)
Me.pnlMain.Controls.Add(Me.txtMotto)
Me.pnlMain.Controls.Add(Me.txtNotfall_Name)
Me.pnlMain.Controls.Add(Me.cbxMotto)
Me.pnlMain.Controls.Add(Me.cbxGeburtsdatumOhneJahr)
Me.pnlMain.Controls.Add(Me.txtHandynummer)
@@ -104,196 +120,21 @@ Partial Class frmMitarbeitersucheBearbeiten
Me.pnlMain.Dock = System.Windows.Forms.DockStyle.Fill
Me.pnlMain.Location = New System.Drawing.Point(0, 0)
Me.pnlMain.Name = "pnlMain"
Me.pnlMain.Size = New System.Drawing.Size(703, 364)
Me.pnlMain.Size = New System.Drawing.Size(703, 525)
Me.pnlMain.TabIndex = 1
'
'cbxAllowFoto
'
Me.cbxAllowFoto.AutoSize = True
Me.cbxAllowFoto.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxAllowFoto.Location = New System.Drawing.Point(7, 187)
Me.cbxAllowFoto.Name = "cbxAllowFoto"
Me.cbxAllowFoto.Size = New System.Drawing.Size(150, 28)
Me.cbxAllowFoto.TabIndex = 33
Me.cbxAllowFoto.Text = "Foto anzeigen"
Me.cbxAllowFoto.UseVisualStyleBackColor = True
'
'btn
'
Me.btn.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.btn.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.btn.Location = New System.Drawing.Point(357, 261)
Me.btn.Name = "btn"
Me.btn.Size = New System.Drawing.Size(333, 51)
Me.btn.TabIndex = 32
Me.btn.Text = "Speichern"
Me.btn.UseVisualStyleBackColor = True
'
'txtMotto
'
Me.txtMotto.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtMotto.Location = New System.Drawing.Point(357, 210)
Me.txtMotto.Name = "txtMotto"
Me.txtMotto.Size = New System.Drawing.Size(333, 29)
Me.txtMotto.TabIndex = 31
'
'cbxMotto
'
Me.cbxMotto.AutoSize = True
Me.cbxMotto.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxMotto.Location = New System.Drawing.Point(186, 212)
Me.cbxMotto.Name = "cbxMotto"
Me.cbxMotto.Size = New System.Drawing.Size(75, 28)
Me.cbxMotto.TabIndex = 30
Me.cbxMotto.Text = "Motto"
Me.cbxMotto.UseVisualStyleBackColor = True
'
'cbxGeburtsdatumOhneJahr
'
Me.cbxGeburtsdatumOhneJahr.AutoSize = True
Me.cbxGeburtsdatumOhneJahr.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxGeburtsdatumOhneJahr.Location = New System.Drawing.Point(489, 110)
Me.cbxGeburtsdatumOhneJahr.Name = "cbxGeburtsdatumOhneJahr"
Me.cbxGeburtsdatumOhneJahr.Size = New System.Drawing.Size(114, 28)
Me.cbxGeburtsdatumOhneJahr.TabIndex = 29
Me.cbxGeburtsdatumOhneJahr.Text = "ohne Jahr"
Me.cbxGeburtsdatumOhneJahr.UseVisualStyleBackColor = True
'
'txtHandynummer
'
Me.txtHandynummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtHandynummer.Location = New System.Drawing.Point(357, 176)
Me.txtHandynummer.Name = "txtHandynummer"
Me.txtHandynummer.Size = New System.Drawing.Size(333, 29)
Me.txtHandynummer.TabIndex = 28
'
'txtSpitzname
'
Me.txtSpitzname.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtSpitzname.Location = New System.Drawing.Point(357, 142)
Me.txtSpitzname.Name = "txtSpitzname"
Me.txtSpitzname.Size = New System.Drawing.Size(333, 29)
Me.txtSpitzname.TabIndex = 27
'
'lblGeburtstag
'
Me.lblGeburtstag.AutoSize = True
Me.lblGeburtstag.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!, System.Drawing.FontStyle.Bold)
Me.lblGeburtstag.Location = New System.Drawing.Point(353, 111)
Me.lblGeburtstag.Name = "lblGeburtstag"
Me.lblGeburtstag.Size = New System.Drawing.Size(110, 24)
Me.lblGeburtstag.TabIndex = 12
Me.lblGeburtstag.Text = "01.01.2020"
Me.lblGeburtstag.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'cbxHandynummer
'
Me.cbxHandynummer.AutoSize = True
Me.cbxHandynummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxHandynummer.Location = New System.Drawing.Point(186, 178)
Me.cbxHandynummer.Name = "cbxHandynummer"
Me.cbxHandynummer.Size = New System.Drawing.Size(155, 28)
Me.cbxHandynummer.TabIndex = 26
Me.cbxHandynummer.Text = "Handynummer"
Me.cbxHandynummer.UseVisualStyleBackColor = True
'
'cbxSpitzname
'
Me.cbxSpitzname.AutoSize = True
Me.cbxSpitzname.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxSpitzname.Location = New System.Drawing.Point(186, 144)
Me.cbxSpitzname.Name = "cbxSpitzname"
Me.cbxSpitzname.Size = New System.Drawing.Size(117, 28)
Me.cbxSpitzname.TabIndex = 25
Me.cbxSpitzname.Text = "Spitzname"
Me.cbxSpitzname.UseVisualStyleBackColor = True
'
'cbxGeburtsdatum
'
Me.cbxGeburtsdatum.AutoSize = True
Me.cbxGeburtsdatum.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxGeburtsdatum.Location = New System.Drawing.Point(186, 110)
Me.cbxGeburtsdatum.Name = "cbxGeburtsdatum"
Me.cbxGeburtsdatum.Size = New System.Drawing.Size(147, 28)
Me.cbxGeburtsdatum.TabIndex = 24
Me.cbxGeburtsdatum.Text = "Geburtsdatum"
Me.cbxGeburtsdatum.UseVisualStyleBackColor = True
'
'cbxWohnort
'
Me.cbxWohnort.AutoSize = True
Me.cbxWohnort.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxWohnort.Location = New System.Drawing.Point(186, 76)
Me.cbxWohnort.Name = "cbxWohnort"
Me.cbxWohnort.Size = New System.Drawing.Size(101, 28)
Me.cbxWohnort.TabIndex = 23
Me.cbxWohnort.Text = "Wohnort"
Me.cbxWohnort.UseVisualStyleBackColor = True
'
'lblWohnadresse
'
Me.lblWohnadresse.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!, System.Drawing.FontStyle.Bold)
Me.lblWohnadresse.Location = New System.Drawing.Point(353, 76)
Me.lblWohnadresse.Name = "lblWohnadresse"
Me.lblWohnadresse.Size = New System.Drawing.Size(341, 28)
Me.lblWohnadresse.TabIndex = 11
Me.lblWohnadresse.Text = "A 4975 Suben"
'
'lblName
'
Me.lblName.BackColor = System.Drawing.Color.Transparent
Me.lblName.Font = New System.Drawing.Font("Microsoft Sans Serif", 30.0!)
Me.lblName.Location = New System.Drawing.Point(178, 6)
Me.lblName.Name = "lblName"
Me.lblName.Size = New System.Drawing.Size(452, 52)
Me.lblName.TabIndex = 1
Me.lblName.Text = "Max Mustermann"
Me.lblName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'pic
'
Me.pic.BackgroundImage = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.personGray_m
Me.pic.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
Me.pic.Cursor = System.Windows.Forms.Cursors.Hand
Me.pic.Location = New System.Drawing.Point(7, 3)
Me.pic.Name = "pic"
Me.pic.Size = New System.Drawing.Size(165, 178)
Me.pic.TabIndex = 0
Me.pic.TabStop = False
'
'pnlHoverPic
'
Me.pnlHoverPic.Controls.Add(Me.PictureBox1)
Me.pnlHoverPic.Controls.Add(Me.PictureBox2)
Me.pnlHoverPic.Controls.Add(Me.txtKonfigHinweis)
Me.pnlHoverPic.Controls.Add(Me.Label1)
Me.pnlHoverPic.Location = New System.Drawing.Point(-1, 232)
Me.pnlHoverPic.Location = New System.Drawing.Point(-1, 280)
Me.pnlHoverPic.Name = "pnlHoverPic"
Me.pnlHoverPic.Size = New System.Drawing.Size(181, 100)
Me.pnlHoverPic.TabIndex = 37
Me.pnlHoverPic.Visible = False
'
'Label1
'
Me.Label1.AutoSize = True
Me.Label1.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.Label1.Location = New System.Drawing.Point(4, 1)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(98, 24)
Me.Label1.TabIndex = 36
Me.Label1.Text = "Hover-Pic:"
'
'PictureBox2
'
Me.PictureBox2.BackgroundImage = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.personGray_m
Me.PictureBox2.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
Me.PictureBox2.Cursor = System.Windows.Forms.Cursors.Hand
Me.PictureBox2.Location = New System.Drawing.Point(77, 29)
Me.PictureBox2.Name = "PictureBox2"
Me.PictureBox2.Size = New System.Drawing.Size(63, 59)
Me.PictureBox2.TabIndex = 35
Me.PictureBox2.TabStop = False
'
'PictureBox1
'
Me.PictureBox1.BackgroundImage = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.personGray_m
@@ -305,6 +146,17 @@ Partial Class frmMitarbeitersucheBearbeiten
Me.PictureBox1.TabIndex = 34
Me.PictureBox1.TabStop = False
'
'PictureBox2
'
Me.PictureBox2.BackgroundImage = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.personGray_m
Me.PictureBox2.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
Me.PictureBox2.Cursor = System.Windows.Forms.Cursors.Hand
Me.PictureBox2.Location = New System.Drawing.Point(77, 29)
Me.PictureBox2.Name = "PictureBox2"
Me.PictureBox2.Size = New System.Drawing.Size(63, 59)
Me.PictureBox2.TabIndex = 35
Me.PictureBox2.TabStop = False
'
'txtKonfigHinweis
'
Me.txtKonfigHinweis.BackColor = System.Drawing.Color.White
@@ -316,13 +168,257 @@ Partial Class frmMitarbeitersucheBearbeiten
Me.txtKonfigHinweis.TabIndex = 38
Me.txtKonfigHinweis.Text = "Sie müssen Ihren Benutzer erstmal konfigurieren, um das Verzeichnis einsehen zu k" &
"önnen. Sie können die Einstellungen jederzeit ändern."
'
'Label1
'
Me.Label1.AutoSize = True
Me.Label1.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.Label1.Location = New System.Drawing.Point(4, 1)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(98, 24)
Me.Label1.TabIndex = 36
Me.Label1.Text = "Hover-Pic:"
'
'cbxAllowFoto
'
Me.cbxAllowFoto.AutoSize = True
Me.cbxAllowFoto.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxAllowFoto.Location = New System.Drawing.Point(7, 235)
Me.cbxAllowFoto.Name = "cbxAllowFoto"
Me.cbxAllowFoto.Size = New System.Drawing.Size(150, 28)
Me.cbxAllowFoto.TabIndex = 33
Me.cbxAllowFoto.Text = "Foto anzeigen"
Me.cbxAllowFoto.UseVisualStyleBackColor = True
'
'btn
'
Me.btn.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.btn.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.btn.Location = New System.Drawing.Point(357, 449)
Me.btn.Name = "btn"
Me.btn.Size = New System.Drawing.Size(333, 51)
Me.btn.TabIndex = 32
Me.btn.Text = "Speichern"
Me.btn.UseVisualStyleBackColor = True
'
'txtNotfall_Name
'
Me.txtNotfall_Name.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtNotfall_Name.Location = New System.Drawing.Point(357, 348)
Me.txtNotfall_Name.Name = "txtNotfall_Name"
Me.txtNotfall_Name.Size = New System.Drawing.Size(333, 29)
Me.txtNotfall_Name.TabIndex = 31
'
'cbxMotto
'
Me.cbxMotto.AutoSize = True
Me.cbxMotto.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxMotto.Location = New System.Drawing.Point(186, 260)
Me.cbxMotto.Name = "cbxMotto"
Me.cbxMotto.Size = New System.Drawing.Size(75, 28)
Me.cbxMotto.TabIndex = 30
Me.cbxMotto.Text = "Motto"
Me.cbxMotto.UseVisualStyleBackColor = True
'
'cbxGeburtsdatumOhneJahr
'
Me.cbxGeburtsdatumOhneJahr.AutoSize = True
Me.cbxGeburtsdatumOhneJahr.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxGeburtsdatumOhneJahr.Location = New System.Drawing.Point(489, 158)
Me.cbxGeburtsdatumOhneJahr.Name = "cbxGeburtsdatumOhneJahr"
Me.cbxGeburtsdatumOhneJahr.Size = New System.Drawing.Size(114, 28)
Me.cbxGeburtsdatumOhneJahr.TabIndex = 29
Me.cbxGeburtsdatumOhneJahr.Text = "ohne Jahr"
Me.cbxGeburtsdatumOhneJahr.UseVisualStyleBackColor = True
'
'txtHandynummer
'
Me.txtHandynummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtHandynummer.Location = New System.Drawing.Point(357, 224)
Me.txtHandynummer.Name = "txtHandynummer"
Me.txtHandynummer.Size = New System.Drawing.Size(333, 29)
Me.txtHandynummer.TabIndex = 28
'
'txtSpitzname
'
Me.txtSpitzname.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtSpitzname.Location = New System.Drawing.Point(357, 190)
Me.txtSpitzname.Name = "txtSpitzname"
Me.txtSpitzname.Size = New System.Drawing.Size(333, 29)
Me.txtSpitzname.TabIndex = 27
'
'lblGeburtstag
'
Me.lblGeburtstag.AutoSize = True
Me.lblGeburtstag.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!, System.Drawing.FontStyle.Bold)
Me.lblGeburtstag.Location = New System.Drawing.Point(353, 159)
Me.lblGeburtstag.Name = "lblGeburtstag"
Me.lblGeburtstag.Size = New System.Drawing.Size(110, 24)
Me.lblGeburtstag.TabIndex = 12
Me.lblGeburtstag.Text = "01.01.2020"
Me.lblGeburtstag.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'cbxHandynummer
'
Me.cbxHandynummer.AutoSize = True
Me.cbxHandynummer.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxHandynummer.Location = New System.Drawing.Point(186, 226)
Me.cbxHandynummer.Name = "cbxHandynummer"
Me.cbxHandynummer.Size = New System.Drawing.Size(155, 28)
Me.cbxHandynummer.TabIndex = 26
Me.cbxHandynummer.Text = "Handynummer"
Me.cbxHandynummer.UseVisualStyleBackColor = True
'
'cbxSpitzname
'
Me.cbxSpitzname.AutoSize = True
Me.cbxSpitzname.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxSpitzname.Location = New System.Drawing.Point(186, 192)
Me.cbxSpitzname.Name = "cbxSpitzname"
Me.cbxSpitzname.Size = New System.Drawing.Size(117, 28)
Me.cbxSpitzname.TabIndex = 25
Me.cbxSpitzname.Text = "Spitzname"
Me.cbxSpitzname.UseVisualStyleBackColor = True
'
'cbxGeburtsdatum
'
Me.cbxGeburtsdatum.AutoSize = True
Me.cbxGeburtsdatum.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxGeburtsdatum.Location = New System.Drawing.Point(186, 158)
Me.cbxGeburtsdatum.Name = "cbxGeburtsdatum"
Me.cbxGeburtsdatum.Size = New System.Drawing.Size(147, 28)
Me.cbxGeburtsdatum.TabIndex = 24
Me.cbxGeburtsdatum.Text = "Geburtsdatum"
Me.cbxGeburtsdatum.UseVisualStyleBackColor = True
'
'cbxWohnort
'
Me.cbxWohnort.AutoSize = True
Me.cbxWohnort.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.cbxWohnort.Location = New System.Drawing.Point(186, 124)
Me.cbxWohnort.Name = "cbxWohnort"
Me.cbxWohnort.Size = New System.Drawing.Size(101, 28)
Me.cbxWohnort.TabIndex = 23
Me.cbxWohnort.Text = "Wohnort"
Me.cbxWohnort.UseVisualStyleBackColor = True
'
'lblWohnadresse
'
Me.lblWohnadresse.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!, System.Drawing.FontStyle.Bold)
Me.lblWohnadresse.Location = New System.Drawing.Point(353, 124)
Me.lblWohnadresse.Name = "lblWohnadresse"
Me.lblWohnadresse.Size = New System.Drawing.Size(341, 28)
Me.lblWohnadresse.TabIndex = 11
Me.lblWohnadresse.Text = "A 4975 Suben"
'
'lblName
'
Me.lblName.BackColor = System.Drawing.Color.Transparent
Me.lblName.Font = New System.Drawing.Font("Microsoft Sans Serif", 30.0!)
Me.lblName.Location = New System.Drawing.Point(178, 54)
Me.lblName.Name = "lblName"
Me.lblName.Size = New System.Drawing.Size(452, 52)
Me.lblName.TabIndex = 1
Me.lblName.Text = "Max Mustermann"
Me.lblName.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'pic
'
Me.pic.BackgroundImage = Global.VERAG_PROG_ALLGEMEIN.My.Resources.Resources.personGray_m
Me.pic.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
Me.pic.Cursor = System.Windows.Forms.Cursors.Hand
Me.pic.Location = New System.Drawing.Point(7, 51)
Me.pic.Name = "pic"
Me.pic.Size = New System.Drawing.Size(165, 178)
Me.pic.TabIndex = 0
Me.pic.TabStop = False
'
'Label2
'
Me.Label2.AutoSize = True
Me.Label2.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!, System.Drawing.FontStyle.Bold)
Me.Label2.Location = New System.Drawing.Point(186, 309)
Me.Label2.Name = "Label2"
Me.Label2.Size = New System.Drawing.Size(139, 24)
Me.Label2.TabIndex = 38
Me.Label2.Text = "Notfallkontakt:"
Me.Label2.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'Label3
'
Me.Label3.AutoSize = True
Me.Label3.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.Label3.Location = New System.Drawing.Point(189, 350)
Me.Label3.Name = "Label3"
Me.Label3.Size = New System.Drawing.Size(66, 24)
Me.Label3.TabIndex = 39
Me.Label3.Text = "Name:"
Me.Label3.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'Label4
'
Me.Label4.AutoSize = True
Me.Label4.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.Label4.Location = New System.Drawing.Point(189, 379)
Me.Label4.Name = "Label4"
Me.Label4.Size = New System.Drawing.Size(141, 24)
Me.Label4.TabIndex = 41
Me.Label4.Text = "Handynummer:"
Me.Label4.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'txtNotfall_Handy
'
Me.txtNotfall_Handy.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtNotfall_Handy.Location = New System.Drawing.Point(357, 376)
Me.txtNotfall_Handy.Name = "txtNotfall_Handy"
Me.txtNotfall_Handy.Size = New System.Drawing.Size(333, 29)
Me.txtNotfall_Handy.TabIndex = 40
'
'Label5
'
Me.Label5.AutoSize = True
Me.Label5.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.Label5.Location = New System.Drawing.Point(189, 406)
Me.Label5.Name = "Label5"
Me.Label5.Size = New System.Drawing.Size(68, 24)
Me.Label5.TabIndex = 43
Me.Label5.Text = "E-Mail:"
Me.Label5.TextAlign = System.Drawing.ContentAlignment.MiddleCenter
'
'txtNotfall_Mail
'
Me.txtNotfall_Mail.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtNotfall_Mail.Location = New System.Drawing.Point(357, 404)
Me.txtNotfall_Mail.Name = "txtNotfall_Mail"
Me.txtNotfall_Mail.Size = New System.Drawing.Size(333, 29)
Me.txtNotfall_Mail.TabIndex = 42
'
'Label6
'
Me.Label6.AutoSize = True
Me.Label6.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
Me.Label6.Location = New System.Drawing.Point(354, 309)
Me.Label6.Name = "Label6"
Me.Label6.Size = New System.Drawing.Size(334, 34)
Me.Label6.TabIndex = 44
Me.Label6.Text = "Nur für mich und berechtigte Personen einsehbar. " & Global.Microsoft.VisualBasic.ChrW(13) & Global.Microsoft.VisualBasic.ChrW(10) & "Im Notfall wird der angegebene" &
" Kontakt verständigt."
Me.Label6.TextAlign = System.Drawing.ContentAlignment.MiddleLeft
'
'txtMotto
'
Me.txtMotto.Font = New System.Drawing.Font("Microsoft Sans Serif", 14.0!)
Me.txtMotto.Location = New System.Drawing.Point(357, 258)
Me.txtMotto.Name = "txtMotto"
Me.txtMotto.Size = New System.Drawing.Size(333, 29)
Me.txtMotto.TabIndex = 45
'
'frmMitarbeitersucheBearbeiten
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.BackColor = System.Drawing.Color.White
Me.ClientSize = New System.Drawing.Size(703, 364)
Me.ClientSize = New System.Drawing.Size(703, 525)
Me.Controls.Add(Me.pnlSrch)
Me.Controls.Add(Me.pnlMain)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None
@@ -333,11 +429,11 @@ Partial Class frmMitarbeitersucheBearbeiten
Me.pnlSrch.ResumeLayout(False)
Me.pnlMain.ResumeLayout(False)
Me.pnlMain.PerformLayout()
CType(Me.pic, System.ComponentModel.ISupportInitialize).EndInit()
Me.pnlHoverPic.ResumeLayout(False)
Me.pnlHoverPic.PerformLayout()
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.PictureBox1, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.PictureBox2, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.pic, System.ComponentModel.ISupportInitialize).EndInit()
Me.ResumeLayout(False)
End Sub
@@ -350,7 +446,7 @@ Partial Class frmMitarbeitersucheBearbeiten
Friend WithEvents lblWohnadresse As Windows.Forms.Label
Friend WithEvents btnClose As Windows.Forms.Button
Friend WithEvents btn As Windows.Forms.Button
Friend WithEvents txtMotto As Windows.Forms.TextBox
Friend WithEvents txtNotfall_Name As Windows.Forms.TextBox
Friend WithEvents cbxMotto As Windows.Forms.CheckBox
Friend WithEvents cbxGeburtsdatumOhneJahr As Windows.Forms.CheckBox
Friend WithEvents txtHandynummer As Windows.Forms.TextBox
@@ -365,4 +461,12 @@ Partial Class frmMitarbeitersucheBearbeiten
Friend WithEvents PictureBox1 As Windows.Forms.PictureBox
Friend WithEvents pnlHoverPic As Windows.Forms.Panel
Friend WithEvents txtKonfigHinweis As Windows.Forms.TextBox
Friend WithEvents Label5 As Windows.Forms.Label
Friend WithEvents txtNotfall_Mail As Windows.Forms.TextBox
Friend WithEvents Label4 As Windows.Forms.Label
Friend WithEvents txtNotfall_Handy As Windows.Forms.TextBox
Friend WithEvents Label3 As Windows.Forms.Label
Friend WithEvents Label2 As Windows.Forms.Label
Public WithEvents Label6 As Windows.Forms.Label
Friend WithEvents txtMotto As Windows.Forms.TextBox
End Class

View File

@@ -44,6 +44,11 @@ Public Class frmMitarbeitersucheBearbeiten
cbxAllowFoto.Checked = MA.mit_MAVerzeichnis_allowFoto
txtNotfall_Name.Text = If(MA.mit_Notfall_Name, "")
txtNotfall_Handy.Text = If(MA.mit_Notfall_Handy, "")
txtNotfall_Mail.Text = If(MA.mit_Notfall_Mail, "")
txtSpitzname.Text = If(MA.mit_MAVerzeichnis_Spitzname, "")
txtHandynummer.Text = If(MA.mit_mobiltel, "")
@@ -138,6 +143,13 @@ Public Class frmMitarbeitersucheBearbeiten
MA.mit_MAVerzeichnis_allowHandynummer = cbxHandynummer.Checked
MA.mit_MAVerzeichnis_allowFoto = cbxAllowFoto.Checked
MA.mit_Notfall_Name = txtNotfall_Name.Text
MA.mit_Notfall_Handy = txtNotfall_Handy.Text
MA.mit_Notfall_Mail = txtNotfall_Mail.Text
If MA.mit_id = VERAG_PROG_ALLGEMEIN.cAllgemein.USRID Then
MA.mit_MAVerzeichnis_SettingsTstmp = Now
End If

View File

@@ -872,6 +872,8 @@ Public Class cNCTS_FREMD
Dim NCTS As New cNCTS_FREMD
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
If MRN Is Nothing Then Return Nothing
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT TOP 1 * FROM tblNCTS_FREMD WHERE [ncts_MRN] LIKE @MRN " & If(checkValidStatus, " AND ncts_status BETWEEN 40 and 90 ", "") & " order by ncts_LetzteBearbeitung desc", conn)
cmd.Parameters.AddWithValue("@MRN", MRN)

View File

@@ -1,14 +1,13 @@
Imports System.Data.SqlClient
Imports System.Net
Imports System.Reflection
Imports System.ServiceModel.Configuration
Imports System.ServiceModel.Security
Imports System.Threading
Imports System.Web.Routing
Imports System.Windows.Forms
Imports System.Windows.Forms.VisualStyles.VisualStyleElement
Imports Chilkat
Imports Newtonsoft.Json.Linq
Imports DocumentFormat.OpenXml.Wordprocessing
Imports javax
Imports javax.xml.ws.soap.AddressingFeature
Imports VERAG_PROG_ALLGEMEIN.VERAG_OUT_NCTS
Public Class cATEZ_NCTS_Sessions
@@ -17,6 +16,7 @@ Public Class cATEZ_NCTS_Sessions
Public Property datetime As DateTime = Now()
Public Property refresh_token As String
Public Property token_validuntil As DateTime
Public Property program As String
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
@@ -30,22 +30,30 @@ Public Class cATEZ_NCTS_Sessions
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("datetime", datetime))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("refresh_token", refresh_token))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("token_validuntil", token_validuntil))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("program", program))
Return list
End Function
Sub New()
LOAD()
LOAD("")
End Sub
Sub New(token As String, refreshtoken As String, timestamp As DateTime)
Sub New(Program As String)
LOAD(Program)
End Sub
Sub New(token As String, refreshtoken As String, timestamp As DateTime, program As String)
Me.token = token
Me.refresh_token = refreshtoken
token_validuntil = timestamp
Me.program = program
SAVE()
End Sub
Public Function SAVE(Optional errHinweis = "") As Boolean
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()
@@ -80,11 +88,11 @@ Public Class cATEZ_NCTS_Sessions
End Function
Public Sub LOAD()
Public Sub LOAD(Program As String)
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT TOP(1) * FROM tblATEZ_NCTS_Sessions where token_validuntil >= dateadd(minute,-10,getdate()) order by datetime desc ", conn)
Using cmd As New SqlCommand("SELECT TOP(1) * FROM tblATEZ_NCTS_Sessions where token_validuntil >= dateadd(minute,-10,getdate()) " & IIf(Program <> "", " AND program = '" & Program & "' ", "") & " order by datetime desc ", conn)
Dim dr = cmd.ExecuteReader()
If dr.Read Then
@@ -621,35 +629,38 @@ Public Class cATEZ_NCTS_IN
Dim SQl As New SQL
Shared apiSettingsloaded As Boolean = False
Sub New(program As String)
Sub New(program As String, Optional errorMessage As Boolean = True)
API = SQl.loadDgvBySql("SELECT top(1) * FROM tblAPIEinstellungen WHERE api_program='" & program & "' and api_productive ='" & If(VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM, "0", "1") & "'", "ADMIN")
If API.Rows.Count = 0 Then
MsgBox("keine gültigen API-Einstellungen für " & program & " gefunden!")
If errorMessage Then MsgBox("keine gültigen API-Einstellungen für " & program & " gefunden!")
Else
apiSettingsloaded = True
API_STRING = API.Rows(0).Item("api_url")
If Not IsDBNull(API.Rows(0).Item("api_debugpath")) AndAlso API.Rows(0).Item("api_debugpath") <> "" Then
Rest.VerboseLogging = True
Rest.DebugLogFilePath = API.Rows(0).Item("api_debugpath") & program & IIf(VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM, "_Test", "") & ".txt"
rest.VerboseLogging = True
rest.DebugLogFilePath = API.Rows(0).Item("api_debugpath") & program & IIf(VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM, "_Test", "") & ".txt"
Else
Rest.VerboseLogging = False
rest.VerboseLogging = False
End If
End If
API_STRING = API.Rows(0).Item("api_url")
End Sub
Shared Function SendRequestAuthentificationToken(ByVal myuri As String, ByVal contentType As String, ByVal method As String, ByRef Itoken As String) As String
Shared Function SendRequestAuthentificationToken(ByVal myuri As String, ByVal contentType As String, ByVal method As String, ByRef Itoken As String, ByVal program As String, Optional client_id As String = "", Optional grant_type As String = "", Optional useBody As Boolean = True) As String
Try
Dim session = New cATEZ_NCTS_Sessions()
If Not IsDBNull(session.token) AndAlso session.token IsNot Nothing Then
Itoken = session.token
token = Itoken
sessionID = session.session_Id
Return "200"
If CDate(session.token_validuntil) < DateTime.Now Then
Itoken = session.token
token = Itoken
sessionID = session.session_Id
Return "200"
End If
End If
If apiSettingsloaded = False Then Return "400"
@@ -663,6 +674,8 @@ Public Class cATEZ_NCTS_IN
Dim bTls As Boolean = True
Dim port As Integer = 443
Dim bAutoReconnect As Boolean = True
'API_STRING = API_STRING.Replace("https://", "")
'API_STRING = API_STRING.Replace("http://", "")
success = rest.Connect(API_STRING, port, bTls, bAutoReconnect)
If (success <> True) Then
Debug.WriteLine("ConnectFailReason: " & rest.ConnectFailReason)
@@ -671,22 +684,41 @@ Public Class cATEZ_NCTS_IN
End If
Dim json As New Chilkat.JsonObject
json.UpdateString("password", API.Rows(0).Item("api_password"))
json.UpdateString("username", API.Rows(0).Item("api_user"))
rest.AddHeader("Content-Type", contentType)
Dim sbRequestBody As New Chilkat.StringBuilder
json.EmitSb(sbRequestBody)
'DEBUG-Mode -> no request will be sent!
'rest.DebugMode = True
Dim sbResponseBody As New Chilkat.StringBuilder
Dim ResponseStr = rest.FullRequestSb(method, myuri, sbRequestBody, sbResponseBody)
Dim ResponseStr As String
If useBody Then
Dim json As New Chilkat.JsonObject
json.UpdateString("username", API.Rows(0).Item("api_user"))
json.UpdateString("password", API.Rows(0).Item("api_password"))
If client_id <> "" Then json.UpdateString("client_id", client_id)
If grant_type <> "" Then json.UpdateString("grant_type", grant_type)
Dim sbRequestBody As New Chilkat.StringBuilder
json.EmitSb(sbRequestBody)
ResponseStr = rest.FullRequestSb(method, myuri, sbRequestBody, sbResponseBody)
Else
rest.ClearAllQueryParams()
rest.AddQueryParam("grant_type", grant_type)
rest.AddQueryParam("username", API.Rows(0).Item("api_user"))
rest.AddQueryParam("password", API.Rows(0).Item("api_password"))
rest.AddQueryParam("client_id", client_id)
ResponseStr = rest.FullRequestFormUrlEncoded(method, myuri)
End If
If (rest.ResponseStatusCode <> 200) Then
@@ -694,13 +726,19 @@ Public Class cATEZ_NCTS_IN
End If
Dim jsonResp = New Chilkat.JsonObject()
jsonResp.LoadSb(sbResponseBody)
If useBody Then
jsonResp.LoadSb(sbResponseBody)
Else
jsonResp.Load(ResponseStr)
End If
Itoken = jsonResp.StringOf("access_token")
token = Itoken
refresh_token = jsonResp.StringOf("refresh_token")
refresh_token = If(jsonResp.StringOf("refresh_token"), "")
Dim now As DateTime = DateTime.Now()
now = now.AddSeconds(jsonResp.IntOf("expires_in"))
session = New cATEZ_NCTS_Sessions(Itoken, refresh_token, now.ToString("yyyy-MM-dd HH:mm:ss"))
session = New cATEZ_NCTS_Sessions(Itoken, refresh_token, now.ToString("yyyy-MM-dd HH:mm:ss"), program)
sessionID = session.session_Id
Return rest.ResponseStatusCode
@@ -710,17 +748,28 @@ Public Class cATEZ_NCTS_IN
End Function
Shared Function authenticate() As String
Shared Function authenticate(program As String, Optional client_id As String = "", Optional grant_type As String = "") As String
Dim myUri As String = API_STRING & "/api/tds/auth/"
Dim response = SendRequestAuthentificationToken(myUri, "application/json", "POST", token)
Dim myUri As String = API_STRING
Dim contentType = "application/json"
Dim useBody As Boolean = True
Select Case program
Case "NCTS" : myUri &= "/api/tds/auth/"
Case "VAT" : myUri &= "/token" : contentType = "application/x-www-form-urlencoded" : useBody = False
End Select
Dim response = SendRequestAuthentificationToken(myUri, contentType, "POST", token, program, client_id, grant_type, useBody)
Return response
End Function
Shared Function SendRequestWithAuthHeader(acceptContentType As String, ByRef failureDesc As String) As String
Shared Function SendRequestWithAuthHeader(acceptContentType As String, ByRef failureDesc As String, myUrl As String, Method As String, Optional dt As DataTable = Nothing) As String
Try
VERAG_PROG_ALLGEMEIN.cChilkat_Helper.UnlockCilkat()
@@ -755,7 +804,7 @@ Public Class cATEZ_NCTS_IN
'rest.PercentDoneOnSend = True
rest.IdleTimeoutMs = 5000 * 31
success = rest.SendReqSb("POST", "/api/integrations/verag", sbRequestBody)
success = rest.SendReqSb(Method, myUrl, sbRequestBody)
Dim responseStatusCode = rest.ReadResponseHeader()
If (responseStatusCode < 0) Then
@@ -804,6 +853,51 @@ Public Class cATEZ_NCTS_IN
Dim jsonResult As New Chilkat.JsonObject
success = jsonResult.LoadSb(sbResponseBody)
jsonResult.Emit()
If dt IsNot Nothing Then
Dim data As New Chilkat.JsonObject
data = jsonResult
If (data.LastMethodSuccess = False) Then
Debug.WriteLine("data member not found.")
End If
Dim num As Integer = 1
If num = -1 Then
Return "FEHLER Array Data ist leer"
End If
Dim j As Integer = 0
While j < num
Dim invoice As Chilkat.JsonObject = data.ObjectAt(j)
Dim R As DataRow = dt.NewRow
R("currency") = checkNullStr(invoice.StringOf("currency"))
Dim totalAmonut As String = invoice.StringOf("total_VAT_amount").Replace(".", ",")
R("total_VAT_amount") = CDbl(checkNulDbl(totalAmonut))
R("invoice_id") = checkNullStr(invoice.StringOf("invoice_id"))
R("invoice_date") = checkNullStr(invoice.StringOf("invoice_date"))
R("seller_VAT_id") = checkNullStr(invoice.StringOf("seller_VAT_id"))
R("seller_address_city") = checkNullStr(invoice.StringOf("seller_address_city"))
R("seller_address_country") = checkNullStr(invoice.StringOf("seller_address_country"))
R("seller_address_postcode") = checkNullStr(invoice.StringOf("seller_address_postcode"))
R("seller_address_street") = checkNullStr(invoice.StringOf("seller_address_street"))
R("status") = checkNullStr(jsonResult.StringOf("status"))
dt.Rows.Add(R)
j = j + 1
End While
Return jsonResult.StringOf("status")
End If
Return jsonResult.StringOf("atezId")
End If
@@ -816,7 +910,24 @@ Public Class cATEZ_NCTS_IN
End Try
End Function
Shared Function setJson(ncts As cATEZ_NCTS_DATA)
Public Shared Function checkNullStr(ByVal o As Object) As String
If o IsNot Nothing AndAlso o IsNot DBNull.Value AndAlso Not o = "null" Then Return CStr(o)
Return ""
End Function
Public Shared Function checkNulDbl(ByVal o As Object) As Double
If o IsNot Nothing And o IsNot DBNull.Value Then
If IsNumeric(o) Then
Return Math.Round(CDbl(o), 2)
Else
Return 0
End If
Else
Return 0
End If
End Function
Shared Function setJsonNCTS(ncts As cATEZ_NCTS_DATA)
jsonData.Clear()
ncts.json = ""
@@ -868,6 +979,21 @@ Public Class cATEZ_NCTS_IN
End Function
Shared Function setJsonVAT(documentType As String, docID As Integer)
jsonData.Clear()
Dim success As Boolean
success = jsonData.UpdateString("document_type", documentType)
Dim base64 As New Chilkat.BinData
success = base64.LoadFile(VERAG_PROG_ALLGEMEIN.cDATENSERVER.GET_PDFPath_BY_DocID(docID))
success = jsonData.UpdateString("document_base64", base64.GetEncoded("base64"))
Return success
End Function
Public Function setJsonPDF(ncts As cATEZ_NCTS_DATA, dgv As DataGridView)
Dim success As Boolean
@@ -894,4 +1020,7 @@ Public Class cATEZ_NCTS_IN
End Function
End Class

View File

@@ -60,6 +60,15 @@ Public Class cHMRC
cHMRCCredentials.CLIENT_ID = cHMRC_ENS.Client_ID
cHMRCCredentials.CLIENT_SECRET = cHMRC_ENS.Client_Secret
End If
Case "ATEZ_ENS"
If VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM Then
Else
cHMRCCredentials.API_STRING = "https://api.service.hmrc.gov.uk"
cHMRCCredentials.CLIENT_ID = "b28AgFVSAXkLPtnnlU1xTRXbMXoD"
cHMRCCredentials.CLIENT_SECRET = "17dfde2d-2aa9-47a0-9a3a-160363b909c5"
End If
End Select
Return cHMRCCredentials
End Function
@@ -1513,9 +1522,10 @@ Public Class cHMRC
Public Shared Function getTOKEN(APPLICATION, Optional forceNewToken = False) As cHMRCToken
Public Shared Function getTOKEN(APPLICATION, Optional forceNewToken = False, Optional saveAPPLICATION_NAME = "", Optional otherHMRCAPPLICATION_NAME = "") As cHMRCToken
If saveAPPLICATION_NAME = "" Then saveAPPLICATION_NAME = APPLICATION
Dim TOKEN = New cHMRCToken(VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA, APPLICATION)
Dim TOKEN = New cHMRCToken(VERAG_PROG_ALLGEMEIN.cAllgemein.FIRMA, saveAPPLICATION_NAME)
Try
Dim appl = ""
Dim HMRC_APPLICATION = "AVISO"
@@ -1538,16 +1548,26 @@ Public Class cHMRC
'appl = "write:import-control-system+read:import-control-system"
appl = "hello"
HMRC_APPLICATION = "AVISO_ENS"
Case Else
appl = "hello"
HMRC_APPLICATION = "AVISO_ENS"
End Select
If otherHMRCAPPLICATION_NAME <> "" Then
HMRC_APPLICATION = otherHMRCAPPLICATION_NAME
End If
If forceNewToken OrElse TOKEN.hasEntry = False OrElse TOKEN.token_BEARER_TOKEN Is Nothing OrElse TOKEN.token_BEARER_TOKEN = "" Then
'Neuer Token
Dim AccessToken = ""
Dim RefreshToken = ""
grantAccess(AccessToken, RefreshToken, appl, HMRC_APPLICATION)
TOKEN.token_Application = APPLICATION
TOKEN.token_Application = saveAPPLICATION_NAME
TOKEN.token_BEARER_TOKEN = AccessToken
TOKEN.token_REFRESH_TOKEN = RefreshToken
TOKEN.token_refresh_datetime = Now

View File

@@ -360,8 +360,15 @@
<Compile Include="Classes\cGestellungsgarantien.vb" />
<Compile Include="Classes\cGestellungsmitteilung.vb" />
<Compile Include="Classes\cGrenzstelle.vb" />
<Compile Include="Classes\cGruppeKundenNr.vb" />
<Compile Include="Classes\cGVMS.vb" />
<Compile Include="Classes\cHandlingssaetzeIntern.vb" />
<Compile Include="frmDatumsabfrage.Designer.vb">
<DependentUpon>frmDatumsabfrage.vb</DependentUpon>
</Compile>
<Compile Include="frmDatumsabfrage.vb">
<SubType>Form</SubType>
</Compile>
<Compile Include="Schnittstellen\cHMRC.vb" />
<Compile Include="Schnittstellen\HMRC\cHMRCToken.vb" />
<Compile Include="Classes\cKundenAufschubkonten.vb" />
@@ -758,6 +765,9 @@
<EmbeddedResource Include="DATENSERVER\frmVorlagenUpload.resx">
<DependentUpon>frmVorlagenUpload.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmDatumsabfrage.resx">
<DependentUpon>frmDatumsabfrage.vb</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="frmErrorMeldung.resx">
<DependentUpon>frmErrorMeldung.vb</DependentUpon>
</EmbeddedResource>

View File

@@ -13,6 +13,7 @@ Public Class cAllgemein
Public Shared ATILLA_SND As Boolean = True
Public Shared CLUSTER As String = "" 'Firmenverbund
Public Shared FIRMEN_GRUPPE As String = "VERAGDCS" 'Firmenverbund-Gruppe
' Public Shared SPECIFIC As cSPECIFIC = New cSPECIFIC
Public Shared ERR_OP_GLOBAL As String = ERROR_OP.SHOW

View File

@@ -5,7 +5,7 @@ Imports System.Windows.Forms
Public Class cErrorHandler
Public Shared Sub ERR(message As String, stack As String, functionName As String, Optional OP As String = "", Optional title As String = "", Optional mailadess As String = "al@verag.ag", Optional recieverMailAdress As String = "", Optional zusatz As String = "", Optional errCode As String = Nothing)
Public Shared Sub ERR(message As String, stack As String, functionName As String, Optional OP As String = "", Optional title As String = "", Optional mailadess As String = "error@verag.ag", Optional recieverMailAdress As String = "", Optional zusatz As String = "", Optional errCode As String = Nothing)
If OP = "" Then OP = VERAG_PROG_ALLGEMEIN.cAllgemein.ERR_OP_GLOBAL ' GLobal gesetzes Errorhandling! (Standart=SHOW)
'If Form.ActiveForm IsNot Nothing Then
@@ -18,19 +18,19 @@ Public Class cErrorHandler
Try
Select Case OP
Case ERROR_OP.MAIL
sendERRORperMail(title & " | " & My.Application.Info.AssemblyName, message, stack, mailadess, zusatz, functionName)
Case ERROR_OP.SHOW
Dim c As New cProgramFunctions
Dim url = c.MakeScreenshot()
Case ERROR_OP.MAIL
sendERRORperMail(title & " | " & My.Application.Info.AssemblyName, message, stack, mailadess, zusatz, functionName)
Case ERROR_OP.SHOW
Dim c As New cProgramFunctions
Dim url = c.MakeScreenshot()
Dim f As New frmErrorMeldung(If(functionName <> "", "Fehler in der Funktion '" & functionName & "'" & vbNewLine & vbNewLine, "") & message & vbNewLine & zusatz, stack, title, url)
f.ShowDialog()
Case ERROR_OP.SHOW_MSGBOX
MsgBox(If(functionName <> "", "Fehler in der Funktion '" & functionName & "'" & vbNewLine & vbNewLine, "") & message & vbNewLine & stack & vbNewLine & zusatz, MsgBoxStyle.OkOnly, If(title <> "", title, "Fehler"))
End Select
Dim f As New frmErrorMeldung(If(functionName <> "", "Fehler in der Funktion '" & functionName & "'" & vbNewLine & vbNewLine, "") & message & vbNewLine & zusatz, stack, title, url)
f.ShowDialog()
Case ERROR_OP.SHOW_MSGBOX
MsgBox(If(functionName <> "", "Fehler in der Funktion '" & functionName & "'" & vbNewLine & vbNewLine, "") & message & vbNewLine & stack & vbNewLine & zusatz, MsgBoxStyle.OkOnly, If(title <> "", title, "Fehler"))
End Select
VERAG_PROG_ALLGEMEIN.cERS.saveErr(OP, message, stack, errCode, functionName, recieverMailAdress, zusatz)
VERAG_PROG_ALLGEMEIN.cERS.saveErr(OP, message, stack, errCode, functionName, recieverMailAdress, zusatz)
Catch ex As Exception
@@ -49,8 +49,10 @@ Public Class cErrorHandler
Dim myCredentials As New System.Net.NetworkCredential
'myCredentials.UserName = "support@verag.ag"
'myCredentials.Password = "$up0Rt2809!"
myCredentials.UserName = "al@verag.ag"
myCredentials.Password = "verag#2"
'myCredentials.UserName = "al@verag.ag"
'myCredentials.Password = "verag#2"
myCredentials.UserName = "edv@verag.ag"
myCredentials.Password = "Ju18WA10"
Msg.IsBodyHtml = False
Dim mySmtpsvr As New SmtpClient()
@@ -60,7 +62,8 @@ Public Class cErrorHandler
mySmtpsvr.Credentials = myCredentials
Try
Msg.From = New MailAddress("al@verag.ag")
' Msg.From = New MailAddress("al@verag.ag")
Msg.From = New MailAddress("edv@verag.ag")
Msg.To.Add(recieverMailAdress)
Msg.Subject = title '"ERROR - DAKOSY Einarbeitung"

View File

@@ -287,7 +287,7 @@ BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object(
End Function
Public Shared Function genExcelFromDT_NEW(dt As DataTable, Optional rangeAsWaehrung() As String = Nothing, Optional ShowAutoFilter As Boolean = True, Optional HeaderTxt As String = "", Optional HeaderTxt2 As String = "", Optional openPDF As Boolean = True, Optional optFileName As String = "", Optional endung As String = ".xlsx", Optional autoAdjust As Boolean = True) As String
Public Shared Function genExcelFromDT_NEW(dt As DataTable, Optional rangeAsWaehrung() As String = Nothing, Optional ShowAutoFilter As Boolean = True, Optional HeaderTxt As String = "", Optional HeaderTxt2 As String = "", Optional openPDF As Boolean = True, Optional optFileName As String = "", Optional endung As String = ".xlsx", Optional autoAdjust As Boolean = False) As String
Try
Dim sPath As String = Environment.GetFolderPath(Environment.SpecialFolder.Personal) & "\VERAG\SDL\tmp\" ' My.Computer.FileSystem.GetTempFileName
@@ -330,7 +330,7 @@ BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object(
End If
Dim filename As String = ""
Dim filename As String = ""
If optFileName <> "" Then
filename = sPath & optFileName & endung '".xlsx"
While System.IO.File.Exists(filename)
@@ -524,7 +524,7 @@ BindingFlags.Instance Or BindingFlags.NonPublic, Nothing, [Control], New Object(
Shared Function getISO2LandFromISO3Land(Iso3Land As String)
If Iso3Land Is Nothing Then Return Nothing
If Iso3Land.Length <> 3 Then Return Nothing
Dim sqlstr = "SELECT TOP 1 isnull(LandKz,'') AS LandKzISO2 from [Länderverzeichnis für die Außenhandelsstatistik] where LandKz_ISO_3 = '" & Iso3Land & "' "
Dim sqlstr = "SELECT TOP 1 isnull(LandKz,'') AS LandKzISO2 from [Länderverzeichnis für die Außenhandelsstatistik] where LandKz_ISO_3 = Replace('" & Iso3Land & "','SLO','SVN')"
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
Return SQL.getValueTxtBySql(sqlstr, "FMZOLL")
End Function

View File

@@ -0,0 +1,175 @@
Imports System.Windows.Forms
<Global.Microsoft.VisualBasic.CompilerServices.DesignerGenerated()>
Partial Class frmDatumsabfrage
Inherits System.Windows.Forms.Form
'Das Formular überschreibt den Löschvorgang, um die Komponentenliste zu bereinigen.
<System.Diagnostics.DebuggerNonUserCode()> _
Protected Overrides Sub Dispose(ByVal disposing As Boolean)
Try
If disposing AndAlso components IsNot Nothing Then
components.Dispose()
End If
Finally
MyBase.Dispose(disposing)
End Try
End Sub
'Wird vom Windows Form-Designer benötigt.
Private components As System.ComponentModel.IContainer
'Hinweis: Die folgende Prozedur ist für den Windows Form-Designer erforderlich.
'Das Bearbeiten ist mit dem Windows Form-Designer möglich.
'Das Bearbeiten mit dem Code-Editor ist nicht möglich.
<System.Diagnostics.DebuggerStepThrough()> _
Private Sub InitializeComponent()
Me.components = New System.ComponentModel.Container()
Me.MyPanel1 = New VERAG_PROG_ALLGEMEIN.MyPanel(Me.components)
Me.pnlKunde = New System.Windows.Forms.Panel()
Me.cboKundenkreis = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.dtp_date = New System.Windows.Forms.DateTimePicker()
Me.btnClose = New System.Windows.Forms.Button()
Me.btn = New System.Windows.Forms.Button()
Me.lbl = New System.Windows.Forms.Label()
Me.Label1 = New System.Windows.Forms.Label()
Me.cbxKunden = New System.Windows.Forms.CheckBox()
Me.MyPanel1.SuspendLayout()
Me.pnlKunde.SuspendLayout()
Me.SuspendLayout()
'
'MyPanel1
'
Me.MyPanel1.BackColor = System.Drawing.Color.White
Me.MyPanel1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle
Me.MyPanel1.Controls.Add(Me.pnlKunde)
Me.MyPanel1.Controls.Add(Me.dtp_date)
Me.MyPanel1.Controls.Add(Me.btnClose)
Me.MyPanel1.Controls.Add(Me.btn)
Me.MyPanel1.Controls.Add(Me.lbl)
Me.MyPanel1.Controls.Add(Me.Label1)
Me.MyPanel1.Dock = System.Windows.Forms.DockStyle.Fill
Me.MyPanel1.Location = New System.Drawing.Point(0, 0)
Me.MyPanel1.Name = "MyPanel1"
Me.MyPanel1.Size = New System.Drawing.Size(264, 84)
Me.MyPanel1.TabIndex = 3
'
'pnlKunde
'
Me.pnlKunde.Controls.Add(Me.cbxKunden)
Me.pnlKunde.Controls.Add(Me.cboKundenkreis)
Me.pnlKunde.Location = New System.Drawing.Point(16, 47)
Me.pnlKunde.Name = "pnlKunde"
Me.pnlKunde.Size = New System.Drawing.Size(169, 32)
Me.pnlKunde.TabIndex = 26
Me.pnlKunde.Visible = False
'
'cboKundenkreis
'
Me.cboKundenkreis._allowedValuesFreiText = Nothing
Me.cboKundenkreis._allowFreiText = False
Me.cboKundenkreis._value = ""
Me.cboKundenkreis.BackColor = System.Drawing.Color.FromArgb(CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer), CType(CType(224, Byte), Integer))
Me.cboKundenkreis.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList
Me.cboKundenkreis.DropDownWidth = 400
Me.cboKundenkreis.Enabled = False
Me.cboKundenkreis.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.cboKundenkreis.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.cboKundenkreis.FormattingEnabled = True
Me.cboKundenkreis.Items.AddRange(New Object() {"", "100000-199999: XXXXXX", "200000-299999: XXXXXX", "300000-399999: XXXXXX", "400000-499999: XXXXXX", "500000-599999: XXXXXX", "600000-699999: XXXXXX", "700000-799999: XXXXXX", "800000-899999: XXXXXX", "900000-999999: XXXXXX"})
Me.cboKundenkreis.Location = New System.Drawing.Point(33, 1)
Me.cboKundenkreis.Name = "cboKundenkreis"
Me.cboKundenkreis.Size = New System.Drawing.Size(133, 28)
Me.cboKundenkreis.TabIndex = 4
'
'dtp_date
'
Me.dtp_date.Format = System.Windows.Forms.DateTimePickerFormat.[Short]
Me.dtp_date.Location = New System.Drawing.Point(16, 24)
Me.dtp_date.Name = "dtp_date"
Me.dtp_date.Size = New System.Drawing.Size(100, 20)
Me.dtp_date.TabIndex = 25
'
'btnClose
'
Me.btnClose.Anchor = CType((System.Windows.Forms.AnchorStyles.Top Or System.Windows.Forms.AnchorStyles.Right), System.Windows.Forms.AnchorStyles)
Me.btnClose.BackColor = System.Drawing.Color.Red
Me.btnClose.FlatAppearance.BorderColor = System.Drawing.Color.White
Me.btnClose.FlatAppearance.BorderSize = 0
Me.btnClose.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.btnClose.Font = New System.Drawing.Font("Microsoft Sans Serif", 7.0!, System.Drawing.FontStyle.Bold)
Me.btnClose.ForeColor = System.Drawing.Color.White
Me.btnClose.Location = New System.Drawing.Point(231, 0)
Me.btnClose.Name = "btnClose"
Me.btnClose.RightToLeft = System.Windows.Forms.RightToLeft.Yes
Me.btnClose.Size = New System.Drawing.Size(31, 20)
Me.btnClose.TabIndex = 5
Me.btnClose.Text = "X"
Me.btnClose.UseVisualStyleBackColor = False
'
'btn
'
Me.btn.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.btn.Font = New System.Drawing.Font("Microsoft Sans Serif", 7.0!)
Me.btn.Location = New System.Drawing.Point(197, 48)
Me.btn.Margin = New System.Windows.Forms.Padding(0)
Me.btn.Name = "btn"
Me.btn.Size = New System.Drawing.Size(57, 22)
Me.btn.TabIndex = 2
Me.btn.Text = "OK"
Me.btn.UseVisualStyleBackColor = True
'
'lbl
'
Me.lbl.AutoSize = True
Me.lbl.Location = New System.Drawing.Point(13, 5)
Me.lbl.Name = "lbl"
Me.lbl.Size = New System.Drawing.Size(215, 13)
Me.lbl.TabIndex = 0
Me.lbl.Text = "Bitte geben Sie das Abrechnungsdatum an: "
'
'Label1
'
Me.Label1.ForeColor = System.Drawing.Color.Red
Me.Label1.Location = New System.Drawing.Point(122, 29)
Me.Label1.Name = "Label1"
Me.Label1.Size = New System.Drawing.Size(132, 18)
Me.Label1.TabIndex = 6
'
'cbxKunden
'
Me.cbxKunden.AutoSize = True
Me.cbxKunden.Location = New System.Drawing.Point(12, 9)
Me.cbxKunden.Name = "cbxKunden"
Me.cbxKunden.Size = New System.Drawing.Size(15, 14)
Me.cbxKunden.TabIndex = 5
Me.cbxKunden.UseVisualStyleBackColor = True
'
'frmDatumsabfrage
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.ClientSize = New System.Drawing.Size(264, 84)
Me.Controls.Add(Me.MyPanel1)
Me.FormBorderStyle = System.Windows.Forms.FormBorderStyle.None
Me.Name = "frmDatumsabfrage"
Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen
Me.Text = "frmDatumsabfrage"
Me.MyPanel1.ResumeLayout(False)
Me.MyPanel1.PerformLayout()
Me.pnlKunde.ResumeLayout(False)
Me.pnlKunde.PerformLayout()
Me.ResumeLayout(False)
End Sub
Friend WithEvents MyPanel1 As VERAG_PROG_ALLGEMEIN.MyPanel
Friend WithEvents btnClose As Button
Friend WithEvents btn As Button
Friend WithEvents lbl As Label
Friend WithEvents Label1 As Label
Friend WithEvents dtp_date As DateTimePicker
Friend WithEvents pnlKunde As Panel
Public WithEvents cboKundenkreis As VERAG_PROG_ALLGEMEIN.MyComboBox
Public WithEvents cbxKunden As CheckBox
End Class

View File

@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>

View File

@@ -0,0 +1,83 @@
Imports System.Windows.Forms
Imports GrapeCity.Viewer.Common.Model
Imports VERAG_PROG_ALLGEMEIN
Public Class frmDatumsabfrage
Dim onlypastDate As Boolean = True
Dim panelKunde As Boolean = False
Sub New()
' Dieser Aufruf ist für den Designer erforderlich.
InitializeComponent()
End Sub
Sub New(title As String, _onlypastDate As Boolean)
' Dieser Aufruf ist für den Designer erforderlich.
InitializeComponent()
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
onlypastDate = _onlypastDate
lbl.Text = title
End Sub
Sub New(title As String, _onlypastDate As Boolean, _mitKundengruppe As Boolean)
' Dieser Aufruf ist für den Designer erforderlich.
InitializeComponent()
' Fügen Sie Initialisierungen nach dem InitializeComponent()-Aufruf hinzu.
onlypastDate = _onlypastDate
lbl.Text = title
panelKunde = _mitKundengruppe
End Sub
Public Datum As Date = CDate(Now.ToShortDateString)
Private Sub btn_Click(sender As Object, e As EventArgs) Handles btn.Click
Label1.Text = ""
If onlypastDate And CDate(dtp_date.Value) > CDate(Now.ToShortDateString) Then
Label1.Text = "Muss heute oder früher sein!"
Me.DialogResult = DialogResult.None
Exit Sub
End If
Datum = CDate(dtp_date.Value)
Me.DialogResult = DialogResult.OK
End Sub
Private Sub dtp_date_KeyDown(sender As Object, e As KeyEventArgs) Handles dtp_date.KeyDown
If e.KeyCode = Keys.Return Then
btn.PerformClick()
End If
End Sub
Private Sub btnClose_Click(sender As Object, e As EventArgs) Handles btnClose.Click
Datum = CDate(Now.ToShortDateString)
Me.Close()
End Sub
Private Sub frmDatumsabfrage(sender As Object, e As EventArgs) Handles Me.Load
dtp_date.Value = Now.ToShortDateString
pnlKunde.Visible = panelKunde
If panelKunde Then
cboKundenkreis.Items.Clear()
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 100000-199999: TR - KUNDEN", "100000-199999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 130000-139999: 360 TR - KUNDEN", "130000-139999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 150000-159999: 360 RMC - KUNDEN", "150000-159999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 140000-149999: 360 DURMAZ - KUNDEN", "140000-149999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 160000-169999: AT - KUNDEN", "160000-169999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 200000-299999: RO - KUNDEN", "200000-299999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 300000-302999: BG - KUNDEN", "300000-302999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 303000-303999: DE - KUNDEN", "303000-303999"))
cboKundenkreis.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(" 400000-499999: YU - KUNDEN", "400000-499999"))
End If
End Sub
Private Sub cbxKunden_CheckedChanged(sender As Object, e As EventArgs) Handles cbxKunden.CheckedChanged
cboKundenkreis.Enabled = cbxKunden.Checked
End Sub
End Class