div. Änderunge, etc.

This commit is contained in:
2026-08-27 13:20:23 +02:00
parent a2974c7319
commit 7fd1e05b29
9 changed files with 318 additions and 139 deletions

View File

@@ -792,7 +792,7 @@ Public Class frmFaktEmail
If Firma_ID = 19 AndAlso RECHNUNG IsNot Nothing AndAlso RECHNUNG.FilialenNr = 4817 AndAlso RECHNUNG.DruckDatumZeit IsNot Nothing Then If Firma_ID = 19 AndAlso RECHNUNG IsNot Nothing AndAlso RECHNUNG.FilialenNr = 4817 AndAlso RECHNUNG.DruckDatumZeit IsNot Nothing Then
Dim SPEDBUCH = New VERAG_PROG_ALLGEMEIN.cSpeditionsbuch(RECHNUNG.FilialenNr, RECHNUNG.AbfertigungsNr, RECHNUNG.UnterNr) Dim SPEDBUCH = New VERAG_PROG_ALLGEMEIN.cSpeditionsbuch(RECHNUNG.FilialenNr, RECHNUNG.AbfertigungsNr, 0)
If SPEDBUCH.hasEntry AndAlso (SPEDBUCH.Abfertigungsart = 114 Or SPEDBUCH.Abfertigungsart = 115) Then If SPEDBUCH.hasEntry AndAlso (SPEDBUCH.Abfertigungsart = 114 Or SPEDBUCH.Abfertigungsart = 115) Then
@@ -815,30 +815,31 @@ Public Class frmFaktEmail
Next Next
If Not hatNichtAbgerechneteVZ Then If Not hatNichtAbgerechneteVZ Then
'Dim ANTR_ERSTATTUNG As New VERAG_PROG_ALLGEMEIN.cUStVErstattungPositionen(USTV_ANTRAG.UStVAn_ID, RECHNUNG.UnterNr + 1) Dim ANTR_ERSTATTUNG As New VERAG_PROG_ALLGEMEIN.cUStVErstattungPositionen(USTV_ANTRAG.UStVAn_ID, RECHNUNG.RechnungsNr, CDate(RECHNUNG.RechnungsDatum))
'If Not ANTR_ERSTATTUNG.hasEntry Then If Not ANTR_ERSTATTUNG.hasEntry Then
' ANTR_ERSTATTUNG.GutschriftsDatum = RECHNUNG.RechnungsDatum ANTR_ERSTATTUNG.GutschriftsDatum = RECHNUNG.RechnungsDatum
' ANTR_ERSTATTUNG.GutschriftsNr = RECHNUNG.RechnungsNr ANTR_ERSTATTUNG.GutschriftsNr = RECHNUNG.RechnungsNr
' ANTR_ERSTATTUNG.UStVEr_Umrechnungskurs = 1 ANTR_ERSTATTUNG.UStVEr_Umrechnungskurs = 1
' ANTR_ERSTATTUNG.UStVEr_USteuerbetrag = bearbGeb ANTR_ERSTATTUNG.UStVEr_USteuerbetrag = 0
' ANTR_ERSTATTUNG.UStVEr_USteuerbetragEUR = bearbGeb ANTR_ERSTATTUNG.UStVEr_USteuerbetragEUR = 0
' ANTR_ERSTATTUNG.SAVE() ANTR_ERSTATTUNG.UStVEr_RK_ID = RECHNUNG.RK_ID
'End If ANTR_ERSTATTUNG.SAVE()
End If
USTV_ANTRAG.UStVAn_VZDatum = RECHNUNG.RechnungsDatum
If IsDBNull(USTV_ANTRAG.UStVAn_VZBetrag) Then If IsDBNull(USTV_ANTRAG.UStVAn_VZBetrag) OrElse USTV_ANTRAG.UStVAn_VZBetrag Is Nothing Then
USTV_ANTRAG.UStVAn_VZBetrag = GUBetrag_ohneBearbeitung USTV_ANTRAG.UStVAn_VZBetrag = GUBetrag_ohneBearbeitung
USTV_ANTRAG.UStVAn_VZDatum = RECHNUNG.RechnungsDatum
USTV_ANTRAG.SAVE()
Else ElseIf IsNumeric(USTV_ANTRAG.UStVAn_VZBetrag) Then
USTV_ANTRAG.UStVAn_VZBetrag += GUBetrag_ohneBearbeitung USTV_ANTRAG.UStVAn_VZBetrag += GUBetrag_ohneBearbeitung
USTV_ANTRAG.UStVAn_VZDatum = RECHNUNG.RechnungsDatum
USTV_ANTRAG.SAVE()
End If End If
USTV_ANTRAG.SAVE()
End If End If
If hatNichtAbgerechneteVZ Then If hatNichtAbgerechneteVZ Then

View File

@@ -31,5 +31,5 @@ Imports System.Runtime.InteropServices
' übernehmen, indem Sie "*" eingeben: ' übernehmen, indem Sie "*" eingeben:
' <Assembly: AssemblyVersion("1.0.*")> ' <Assembly: AssemblyVersion("1.0.*")>
<Assembly: AssemblyVersion("1.5.7.5")> <Assembly: AssemblyVersion("1.5.7.6")>
<Assembly: AssemblyFileVersion("1.5.7.5")> <Assembly: AssemblyFileVersion("1.5.7.6")>

View File

@@ -33,6 +33,7 @@ Partial Class usrCntlSMS
Me.Button6 = New System.Windows.Forms.Button() Me.Button6 = New System.Windows.Forms.Button()
Me.Button5 = New System.Windows.Forms.Button() Me.Button5 = New System.Windows.Forms.Button()
Me.pnloptions = New System.Windows.Forms.Panel() Me.pnloptions = New System.Windows.Forms.Panel()
Me.Button3 = New System.Windows.Forms.Button()
Me.Button1 = New System.Windows.Forms.Button() Me.Button1 = New System.Windows.Forms.Button()
Me.Button2 = New System.Windows.Forms.Button() Me.Button2 = New System.Windows.Forms.Button()
Me.FlatButton7 = New System.Windows.Forms.Button() Me.FlatButton7 = New System.Windows.Forms.Button()
@@ -56,13 +57,16 @@ Partial Class usrCntlSMS
Me.Label12 = New System.Windows.Forms.Label() Me.Label12 = New System.Windows.Forms.Label()
Me.DateTimePicker1 = New System.Windows.Forms.DateTimePicker() Me.DateTimePicker1 = New System.Windows.Forms.DateTimePicker()
Me.pnl = New System.Windows.Forms.Panel() Me.pnl = New System.Windows.Forms.Panel()
Me.Label5 = New System.Windows.Forms.Label()
Me.lblgesendetOK = New System.Windows.Forms.Label()
Me.Label3 = New System.Windows.Forms.Label()
Me.cboAbsedner = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.cboAbsedner = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.Label1 = New System.Windows.Forms.Label() Me.Label1 = New System.Windows.Forms.Label()
Me.Label8 = New System.Windows.Forms.Label() Me.Label8 = New System.Windows.Forms.Label()
Me.cntxtOptionen = New System.Windows.Forms.ContextMenuStrip(Me.components) Me.cntxtOptionen = New System.Windows.Forms.ContextMenuStrip(Me.components)
Me.AbgeholtToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.AbgeholtToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.StornoToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.StornoToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.Button3 = New System.Windows.Forms.Button() Me.lblFehlerhaft = New System.Windows.Forms.Label()
Me.pnloptions.SuspendLayout() Me.pnloptions.SuspendLayout()
Me.pnlTop.SuspendLayout() Me.pnlTop.SuspendLayout()
Me.Panel1.SuspendLayout() Me.Panel1.SuspendLayout()
@@ -80,7 +84,7 @@ Partial Class usrCntlSMS
Me.cboSachbearbeiter.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems Me.cboSachbearbeiter.AutoCompleteSource = System.Windows.Forms.AutoCompleteSource.ListItems
Me.cboSachbearbeiter.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) Me.cboSachbearbeiter.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.cboSachbearbeiter.FormattingEnabled = True Me.cboSachbearbeiter.FormattingEnabled = True
Me.cboSachbearbeiter.Location = New System.Drawing.Point(435, 78) Me.cboSachbearbeiter.Location = New System.Drawing.Point(444, 77)
Me.cboSachbearbeiter.Name = "cboSachbearbeiter" Me.cboSachbearbeiter.Name = "cboSachbearbeiter"
Me.cboSachbearbeiter.Size = New System.Drawing.Size(168, 24) Me.cboSachbearbeiter.Size = New System.Drawing.Size(168, 24)
Me.cboSachbearbeiter.TabIndex = 21 Me.cboSachbearbeiter.TabIndex = 21
@@ -90,10 +94,12 @@ Partial Class usrCntlSMS
Me.txtAbfertDatBis._DateTimeOnly = False Me.txtAbfertDatBis._DateTimeOnly = False
Me.txtAbfertDatBis._numbersOnly = False Me.txtAbfertDatBis._numbersOnly = False
Me.txtAbfertDatBis._numbersOnlyKommastellen = "" Me.txtAbfertDatBis._numbersOnlyKommastellen = ""
Me.txtAbfertDatBis._numbersOnlyTrennzeichen = True
Me.txtAbfertDatBis._Prozent = False Me.txtAbfertDatBis._Prozent = False
Me.txtAbfertDatBis._ShortDateNew = True Me.txtAbfertDatBis._ShortDateNew = True
Me.txtAbfertDatBis._ShortDateOnly = False Me.txtAbfertDatBis._ShortDateOnly = False
Me.txtAbfertDatBis._TimeOnly = False Me.txtAbfertDatBis._TimeOnly = False
Me.txtAbfertDatBis._TimeOnly_Seconds = False
Me.txtAbfertDatBis._value = "" Me.txtAbfertDatBis._value = ""
Me.txtAbfertDatBis._Waehrung = False Me.txtAbfertDatBis._Waehrung = False
Me.txtAbfertDatBis._WaehrungZeichen = True Me.txtAbfertDatBis._WaehrungZeichen = True
@@ -113,10 +119,12 @@ Partial Class usrCntlSMS
Me.txtAbfertDat._DateTimeOnly = False Me.txtAbfertDat._DateTimeOnly = False
Me.txtAbfertDat._numbersOnly = False Me.txtAbfertDat._numbersOnly = False
Me.txtAbfertDat._numbersOnlyKommastellen = "" Me.txtAbfertDat._numbersOnlyKommastellen = ""
Me.txtAbfertDat._numbersOnlyTrennzeichen = True
Me.txtAbfertDat._Prozent = False Me.txtAbfertDat._Prozent = False
Me.txtAbfertDat._ShortDateNew = True Me.txtAbfertDat._ShortDateNew = True
Me.txtAbfertDat._ShortDateOnly = False Me.txtAbfertDat._ShortDateOnly = False
Me.txtAbfertDat._TimeOnly = False Me.txtAbfertDat._TimeOnly = False
Me.txtAbfertDat._TimeOnly_Seconds = False
Me.txtAbfertDat._value = "" Me.txtAbfertDat._value = ""
Me.txtAbfertDat._Waehrung = False Me.txtAbfertDat._Waehrung = False
Me.txtAbfertDat._WaehrungZeichen = True Me.txtAbfertDat._WaehrungZeichen = True
@@ -148,16 +156,18 @@ Partial Class usrCntlSMS
Me.txtHandyNr._DateTimeOnly = False Me.txtHandyNr._DateTimeOnly = False
Me.txtHandyNr._numbersOnly = False Me.txtHandyNr._numbersOnly = False
Me.txtHandyNr._numbersOnlyKommastellen = "" Me.txtHandyNr._numbersOnlyKommastellen = ""
Me.txtHandyNr._numbersOnlyTrennzeichen = True
Me.txtHandyNr._Prozent = False Me.txtHandyNr._Prozent = False
Me.txtHandyNr._ShortDateNew = False Me.txtHandyNr._ShortDateNew = False
Me.txtHandyNr._ShortDateOnly = False Me.txtHandyNr._ShortDateOnly = False
Me.txtHandyNr._TimeOnly = False Me.txtHandyNr._TimeOnly = False
Me.txtHandyNr._TimeOnly_Seconds = False
Me.txtHandyNr._value = "" Me.txtHandyNr._value = ""
Me.txtHandyNr._Waehrung = False Me.txtHandyNr._Waehrung = False
Me.txtHandyNr._WaehrungZeichen = True Me.txtHandyNr._WaehrungZeichen = True
Me.txtHandyNr.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) Me.txtHandyNr.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.txtHandyNr.ForeColor = System.Drawing.Color.Black Me.txtHandyNr.ForeColor = System.Drawing.Color.Black
Me.txtHandyNr.Location = New System.Drawing.Point(435, 57) Me.txtHandyNr.Location = New System.Drawing.Point(444, 52)
Me.txtHandyNr.MaxLineLength = -1 Me.txtHandyNr.MaxLineLength = -1
Me.txtHandyNr.MaxLines_Warning = "" Me.txtHandyNr.MaxLines_Warning = ""
Me.txtHandyNr.MaxLines_Warning_Label = Nothing Me.txtHandyNr.MaxLines_Warning_Label = Nothing
@@ -225,6 +235,19 @@ Partial Class usrCntlSMS
Me.pnloptions.Size = New System.Drawing.Size(1111, 59) Me.pnloptions.Size = New System.Drawing.Size(1111, 59)
Me.pnloptions.TabIndex = 2 Me.pnloptions.TabIndex = 2
' '
'Button3
'
Me.Button3.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.Button3.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button3.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button3.Location = New System.Drawing.Point(226, 5)
Me.Button3.Margin = New System.Windows.Forms.Padding(0)
Me.Button3.Name = "Button3"
Me.Button3.Size = New System.Drawing.Size(104, 45)
Me.Button3.TabIndex = 10
Me.Button3.Text = "Status Link"
Me.Button3.UseVisualStyleBackColor = True
'
'Button1 'Button1
' '
Me.Button1.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles) Me.Button1.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
@@ -284,10 +307,12 @@ Partial Class usrCntlSMS
Me.txtMaxSrch._DateTimeOnly = False Me.txtMaxSrch._DateTimeOnly = False
Me.txtMaxSrch._numbersOnly = True Me.txtMaxSrch._numbersOnly = True
Me.txtMaxSrch._numbersOnlyKommastellen = "" Me.txtMaxSrch._numbersOnlyKommastellen = ""
Me.txtMaxSrch._numbersOnlyTrennzeichen = True
Me.txtMaxSrch._Prozent = False Me.txtMaxSrch._Prozent = False
Me.txtMaxSrch._ShortDateNew = False Me.txtMaxSrch._ShortDateNew = False
Me.txtMaxSrch._ShortDateOnly = False Me.txtMaxSrch._ShortDateOnly = False
Me.txtMaxSrch._TimeOnly = False Me.txtMaxSrch._TimeOnly = False
Me.txtMaxSrch._TimeOnly_Seconds = False
Me.txtMaxSrch._value = "" Me.txtMaxSrch._value = ""
Me.txtMaxSrch._Waehrung = False Me.txtMaxSrch._Waehrung = False
Me.txtMaxSrch._WaehrungZeichen = True Me.txtMaxSrch._WaehrungZeichen = True
@@ -523,6 +548,10 @@ Partial Class usrCntlSMS
' '
Me.pnl.BackColor = System.Drawing.Color.WhiteSmoke Me.pnl.BackColor = System.Drawing.Color.WhiteSmoke
Me.pnl.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle Me.pnl.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle
Me.pnl.Controls.Add(Me.lblFehlerhaft)
Me.pnl.Controls.Add(Me.Label5)
Me.pnl.Controls.Add(Me.lblgesendetOK)
Me.pnl.Controls.Add(Me.Label3)
Me.pnl.Controls.Add(Me.cboAbsedner) Me.pnl.Controls.Add(Me.cboAbsedner)
Me.pnl.Controls.Add(Me.Label1) Me.pnl.Controls.Add(Me.Label1)
Me.pnl.Controls.Add(Me.Label8) Me.pnl.Controls.Add(Me.Label8)
@@ -553,6 +582,36 @@ Partial Class usrCntlSMS
Me.pnl.Size = New System.Drawing.Size(1111, 140) Me.pnl.Size = New System.Drawing.Size(1111, 140)
Me.pnl.TabIndex = 0 Me.pnl.TabIndex = 0
' '
'Label5
'
Me.Label5.AutoSize = True
Me.Label5.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label5.Location = New System.Drawing.Point(631, 109)
Me.Label5.Name = "Label5"
Me.Label5.Size = New System.Drawing.Size(61, 13)
Me.Label5.TabIndex = 39
Me.Label5.Text = "fehlerhaft"
'
'lblgesendetOK
'
Me.lblgesendetOK.AutoSize = True
Me.lblgesendetOK.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.lblgesendetOK.Location = New System.Drawing.Point(787, 92)
Me.lblgesendetOK.Name = "lblgesendetOK"
Me.lblgesendetOK.Size = New System.Drawing.Size(11, 13)
Me.lblgesendetOK.TabIndex = 38
Me.lblgesendetOK.Text = "."
'
'Label3
'
Me.Label3.AutoSize = True
Me.Label3.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label3.Location = New System.Drawing.Point(631, 87)
Me.Label3.Name = "Label3"
Me.Label3.Size = New System.Drawing.Size(95, 13)
Me.Label3.TabIndex = 37
Me.Label3.Text = "erfolgreich ges."
'
'cboAbsedner 'cboAbsedner
' '
Me.cboAbsedner._allowedValuesFreiText = Nothing Me.cboAbsedner._allowedValuesFreiText = Nothing
@@ -607,18 +666,15 @@ Partial Class usrCntlSMS
Me.StornoToolStripMenuItem.Size = New System.Drawing.Size(123, 22) Me.StornoToolStripMenuItem.Size = New System.Drawing.Size(123, 22)
Me.StornoToolStripMenuItem.Text = "Storno" Me.StornoToolStripMenuItem.Text = "Storno"
' '
'Button3 'lblFehlerhaft
' '
Me.Button3.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles) Me.lblFehlerhaft.AutoSize = True
Me.Button3.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.lblFehlerhaft.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Button3.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft Me.lblFehlerhaft.Location = New System.Drawing.Point(787, 113)
Me.Button3.Location = New System.Drawing.Point(226, 5) Me.lblFehlerhaft.Name = "lblFehlerhaft"
Me.Button3.Margin = New System.Windows.Forms.Padding(0) Me.lblFehlerhaft.Size = New System.Drawing.Size(11, 13)
Me.Button3.Name = "Button3" Me.lblFehlerhaft.TabIndex = 42
Me.Button3.Size = New System.Drawing.Size(104, 45) Me.lblFehlerhaft.Text = "."
Me.Button3.TabIndex = 10
Me.Button3.Text = "Status Link"
Me.Button3.UseVisualStyleBackColor = True
' '
'usrCntlSMS 'usrCntlSMS
' '
@@ -680,4 +736,8 @@ Partial Class usrCntlSMS
Friend WithEvents Label1 As System.Windows.Forms.Label Friend WithEvents Label1 As System.Windows.Forms.Label
Friend WithEvents Button1 As Button Friend WithEvents Button1 As Button
Friend WithEvents Button3 As Button Friend WithEvents Button3 As Button
Friend WithEvents lblgesendetOK As Label
Friend WithEvents Label3 As Label
Friend WithEvents Label5 As Label
Friend WithEvents lblFehlerhaft As Label
End Class End Class

View File

@@ -1,4 +1,5 @@
Imports com.esendex.sdk.sent Imports com.esendex.sdk.sent
Imports java.rmi.dgc
Public Class usrCntlSMS Public Class usrCntlSMS
@@ -175,6 +176,19 @@ Public Class usrCntlSMS
End With End With
showDGV() showDGV()
Dim OK As Integer = 0
Dim failed As Integer = 0
For Each r As DataGridViewRow In MyDatagridview1.Rows
If r.Cells("Status").Value = "OK" Then
OK += 1
ElseIf r.Cells("Status").Value = "FEHLER" Then
failed += 1
End If
Next
lblgesendetOK.Text = OK & " / " & MyDatagridview1.Rows.Count
lblFehlerhaft.Text = failed & " / " & MyDatagridview1.Rows.Count
Me.Cursor = Cursors.Default Me.Cursor = Cursors.Default
End Sub End Sub
@@ -399,5 +413,7 @@ Public Class usrCntlSMS
End If End If
End Sub End Sub
End Class End Class

View File

@@ -58,6 +58,8 @@ Partial Class frmMDM_USTVAntrag
Me.cbxLand = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.cbxLand = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.lblLand = New System.Windows.Forms.Label() Me.lblLand = New System.Windows.Forms.Label()
Me.Panel8 = New System.Windows.Forms.Panel() Me.Panel8 = New System.Windows.Forms.Panel()
Me.Label21 = New System.Windows.Forms.Label()
Me.txtErstattung = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.txtVZOffen = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.txtVZOffen = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.Label19 = New System.Windows.Forms.Label() Me.Label19 = New System.Windows.Forms.Label()
Me.btnSortNachLeist = New System.Windows.Forms.Button() Me.btnSortNachLeist = New System.Windows.Forms.Button()
@@ -152,8 +154,6 @@ Partial Class frmMDM_USTVAntrag
Me.ToolStripMenuItem2 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem2 = New System.Windows.Forms.ToolStripMenuItem()
Me.ToolStripMenuItem3 = New System.Windows.Forms.ToolStripMenuItem() Me.ToolStripMenuItem3 = New System.Windows.Forms.ToolStripMenuItem()
Me.FakturiertToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.FakturiertToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.txtErstattung = New VERAG_PROG_ALLGEMEIN.MyTextBox()
Me.Label21 = New System.Windows.Forms.Label()
Me.pnlBottom.SuspendLayout() Me.pnlBottom.SuspendLayout()
CType(Me.pbXMLExport, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.pbXMLExport, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.pbMail, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.pbMail, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -676,6 +676,45 @@ Partial Class frmMDM_USTVAntrag
Me.Panel8.Size = New System.Drawing.Size(963, 144) Me.Panel8.Size = New System.Drawing.Size(963, 144)
Me.Panel8.TabIndex = 19 Me.Panel8.TabIndex = 19
' '
'Label21
'
Me.Label21.AutoSize = True
Me.Label21.BackColor = System.Drawing.Color.Transparent
Me.Label21.Cursor = System.Windows.Forms.Cursors.Hand
Me.Label21.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label21.ForeColor = System.Drawing.Color.Black
Me.Label21.Location = New System.Drawing.Point(524, 119)
Me.Label21.Name = "Label21"
Me.Label21.Size = New System.Drawing.Size(77, 17)
Me.Label21.TabIndex = 62
Me.Label21.Text = "Erstattung:"
'
'txtErstattung
'
Me.txtErstattung._DateTimeOnly = False
Me.txtErstattung._numbersOnly = True
Me.txtErstattung._numbersOnlyKommastellen = "2"
Me.txtErstattung._numbersOnlyTrennzeichen = True
Me.txtErstattung._Prozent = False
Me.txtErstattung._ShortDateNew = False
Me.txtErstattung._ShortDateOnly = False
Me.txtErstattung._TimeOnly = False
Me.txtErstattung._TimeOnly_Seconds = False
Me.txtErstattung._value = ""
Me.txtErstattung._Waehrung = True
Me.txtErstattung._WaehrungZeichen = True
Me.txtErstattung.Enabled = False
Me.txtErstattung.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
Me.txtErstattung.ForeColor = System.Drawing.Color.Black
Me.txtErstattung.Location = New System.Drawing.Point(654, 114)
Me.txtErstattung.MaxLength = 10
Me.txtErstattung.MaxLineLength = -1
Me.txtErstattung.MaxLines_Warning = ""
Me.txtErstattung.MaxLines_Warning_Label = Nothing
Me.txtErstattung.Name = "txtErstattung"
Me.txtErstattung.Size = New System.Drawing.Size(125, 23)
Me.txtErstattung.TabIndex = 61
'
'txtVZOffen 'txtVZOffen
' '
Me.txtVZOffen._DateTimeOnly = False Me.txtVZOffen._DateTimeOnly = False
@@ -1977,45 +2016,6 @@ Partial Class frmMDM_USTVAntrag
Me.FakturiertToolStripMenuItem.Text = "Fakturiert zurücksetzen" Me.FakturiertToolStripMenuItem.Text = "Fakturiert zurücksetzen"
Me.FakturiertToolStripMenuItem.Visible = False Me.FakturiertToolStripMenuItem.Visible = False
' '
'txtErstattung
'
Me.txtErstattung._DateTimeOnly = False
Me.txtErstattung._numbersOnly = True
Me.txtErstattung._numbersOnlyKommastellen = "2"
Me.txtErstattung._numbersOnlyTrennzeichen = True
Me.txtErstattung._Prozent = False
Me.txtErstattung._ShortDateNew = False
Me.txtErstattung._ShortDateOnly = False
Me.txtErstattung._TimeOnly = False
Me.txtErstattung._TimeOnly_Seconds = False
Me.txtErstattung._value = ""
Me.txtErstattung._Waehrung = True
Me.txtErstattung._WaehrungZeichen = True
Me.txtErstattung.Enabled = False
Me.txtErstattung.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!)
Me.txtErstattung.ForeColor = System.Drawing.Color.Black
Me.txtErstattung.Location = New System.Drawing.Point(654, 114)
Me.txtErstattung.MaxLength = 10
Me.txtErstattung.MaxLineLength = -1
Me.txtErstattung.MaxLines_Warning = ""
Me.txtErstattung.MaxLines_Warning_Label = Nothing
Me.txtErstattung.Name = "txtErstattung"
Me.txtErstattung.Size = New System.Drawing.Size(125, 23)
Me.txtErstattung.TabIndex = 61
'
'Label21
'
Me.Label21.AutoSize = True
Me.Label21.BackColor = System.Drawing.Color.Transparent
Me.Label21.Cursor = System.Windows.Forms.Cursors.Hand
Me.Label21.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label21.ForeColor = System.Drawing.Color.Black
Me.Label21.Location = New System.Drawing.Point(524, 119)
Me.Label21.Name = "Label21"
Me.Label21.Size = New System.Drawing.Size(77, 17)
Me.Label21.TabIndex = 62
Me.Label21.Text = "Erstattung:"
'
'frmMDM_USTVAntrag 'frmMDM_USTVAntrag
' '
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)

View File

@@ -24,6 +24,7 @@ Public Class frmMDM_USTVAntrag
Dim GesamtUSteuerEUR As Double Dim GesamtUSteuerEUR As Double
Dim GesamtUSteuer As Double Dim GesamtUSteuer As Double
Dim looked As Boolean = False Dim looked As Boolean = False
Dim suppressSelectionChanged = False
Sub New(UStVAn_ID) Sub New(UStVAn_ID)
@@ -51,22 +52,25 @@ Public Class frmMDM_USTVAntrag
End Sub End Sub
Sub init(Optional posIndex As Integer = -1, Optional Lieferant As String = "") Sub init(Optional posIndex As Integer = -1, Optional Lieferant As String = "")
suppressSelectionChanged = True
pnlBody.AutoScroll = False pnlBody.AutoScroll = False
lblGesamtUSteuerFW.Text = "-" lblGesamtUSteuerFW.Text = "-"
lblGesamtErstattungFW.Text = "-" lblGesamtErstattungFW.Text = "-"
lblDiffernezbetragFW.Text = "-" lblDiffernezbetragFW.Text = "-"
lblGesamtUSteuer.Text="-" lblGesamtUSteuer.Text = "-"
lblGesamtErstattung.Text = "-" lblGesamtErstattung.Text = "-"
lblDiffernezbetrag.Text = "-" lblDiffernezbetrag.Text = "-"
lblVZAenderungsdatum.Text = "-" lblVZAenderungsdatum.Text = "-"
btnAntrageeinarbeiten.Enabled = Not UStVAn_ID <= 0 btnAntrageeinarbeiten.Enabled = Not UStVAn_ID <= 0
FlowLayoutPanel.Enabled= Not UStVAn_ID <= 0 FlowLayoutPanel.Enabled = Not UStVAn_ID <= 0
btnEintragloeschen.Enabled= Not UStVAn_ID <= 0 btnEintragloeschen.Enabled = Not UStVAn_ID <= 0
btnNeuerEintrag.Enabled= Not UStVAn_ID <= 0 btnNeuerEintrag.Enabled = Not UStVAn_ID <= 0
UstCntlUSTV_AntragPosition1.Enabled= Not UStVAn_ID <= 0 UstCntlUSTV_AntragPosition1.Enabled = Not UStVAn_ID <= 0
cbxLand.Visible = UStVAn_ID <= 0 cbxLand.Visible = UStVAn_ID <= 0
With dgvUSTVPositionen With dgvUSTVPositionen
@@ -301,71 +305,71 @@ Public Class frmMDM_USTVAntrag
Dim KUNDE As New cKunde(USTV_ANTRAG.UStVAn_KuNr) Dim KUNDE As New cKunde(USTV_ANTRAG.UStVAn_KuNr)
Dim KUNDE_ERW As New cKundenErweitert(USTV_ANTRAG.UStVAn_KuNr) Dim KUNDE_ERW As New cKundenErweitert(USTV_ANTRAG.UStVAn_KuNr)
If KUNDE IsNot Nothing Then If KUNDE IsNot Nothing Then
pnlHeader.BackColor = Color.FromArgb(0, 54, 128) pnlHeader.BackColor = Color.FromArgb(0, 54, 128)
If KUNDE.Abfertigungsverbot Then pnlHeader.BackColor = Color.IndianRed If KUNDE.Abfertigungsverbot Then pnlHeader.BackColor = Color.IndianRed
Else
pnlHeader.BackColor = Color.FromArgb(0, 54, 128)
End If
If USTV_ANTRAG.UStVAn_AntragEingereichtAm IsNot Nothing AndAlso IsDate(USTV_ANTRAG.UStVAn_AntragEingereichtAm) Then
looked = True
Else
looked = False
End If
lookFields(looked)
If KUNDE_ERW IsNot Nothing Then
If KUNDE_ERW.kde_MWStAbrechnung <> "" Then
lblMWSTAntrag.Text = KUNDE_ERW.kde_MWStAbrechnung
Else Else
pnlHeader.BackColor = Color.FromArgb(0, 54, 128) lblMWSTAntrag.Text = ""
End If End If
If KUNDE_ERW.kde_AnmerkungAntrag IsNot Nothing AndAlso KUNDE_ERW.kde_AnmerkungAntrag <> "" Then lblMWSTAntrag.Text &= " - " & KUNDE_ERW.kde_AnmerkungAntrag
End If
If USTV_ANTRAG.UStVAn_AntragEingereichtAm IsNot Nothing AndAlso IsDate(USTV_ANTRAG.UStVAn_AntragEingereichtAm) Then If USTV_ANTRAG.FilialenNr IsNot Nothing AndAlso USTV_ANTRAG.FilialenNr > 0 AndAlso USTV_ANTRAG.AbfertigungsNr IsNot Nothing AndAlso USTV_ANTRAG.AbfertigungsNr > 0 Then
looked = True Dim spedBuch As New cSpeditionsbuch(USTV_ANTRAG.FilialenNr, USTV_ANTRAG.AbfertigungsNr, 0)
Else If spedBuch.hasEntry Then
looked = False
End If
lookFields(looked) If CInt(SQL.getValueTxtBySql("select COUNT(*) from Rechnungsausgang where FilialenNr = " & USTV_ANTRAG.FilialenNr & " and AbfertigungsNr = " & USTV_ANTRAG.AbfertigungsNr & " and Firma_ID = 19 and DruckDatumZeit is not null", "FMZOLL",,, "0")) > 0 Then
pb_Beleg.Visible = True
If KUNDE_ERW IsNot Nothing Then
If KUNDE_ERW.kde_MWStAbrechnung <> "" Then
lblMWSTAntrag.Text = KUNDE_ERW.kde_MWStAbrechnung
Else Else
lblMWSTAntrag.Text = "" pb_Beleg.Visible = False
End If End If
If KUNDE_ERW.kde_AnmerkungAntrag IsNot Nothing AndAlso KUNDE_ERW.kde_AnmerkungAntrag <> "" Then lblMWSTAntrag.Text &= " - " & KUNDE_ERW.kde_AnmerkungAntrag
End If
If USTV_ANTRAG.FilialenNr IsNot Nothing AndAlso USTV_ANTRAG.FilialenNr > 0 AndAlso USTV_ANTRAG.AbfertigungsNr IsNot Nothing AndAlso USTV_ANTRAG.AbfertigungsNr > 0 Then Button4.Text = "Sped.-Buch anzeigen"
Dim spedBuch As New cSpeditionsbuch(USTV_ANTRAG.FilialenNr, USTV_ANTRAG.AbfertigungsNr, 0) Button5.Visible = True
If spedBuch.hasEntry Then
If CInt(SQL.getValueTxtBySql("select COUNT(*) from Rechnungsausgang where FilialenNr = " & USTV_ANTRAG.FilialenNr & " and AbfertigungsNr = " & USTV_ANTRAG.AbfertigungsNr & " and Firma_ID = 19 and DruckDatumZeit is not null", "FMZOLL",,, "0")) > 0 Then
pb_Beleg.Visible = True
Else
pb_Beleg.Visible = False
End If
Button4.Text = "Sped.-Buch anzeigen"
Button5.Visible = True
Else
Button4.Text = "Sped.-Buch eintragen"
Button5.Visible = False
End If
Else Else
Button4.Text = "Sped.-Buch eintragen" Button4.Text = "Sped.-Buch eintragen"
Button5.Visible = False Button5.Visible = False
End If End If
Else
Button4.Text = "Sped.-Buch eintragen"
Button5.Visible = False
End If End If
End If
If posIndex > 0 Then If posIndex > 0 Then
posIndex = posIndex - 1 Dim idx As Integer = posIndex - 1
If posIndex > 0 And dgvUSTVPositionen.Rows.Count > posIndex Then If idx >= 0 AndAlso dgvUSTVPositionen.Rows.Count > idx Then
dgvUSTVPositionen.ClearSelection() dgvUSTVPositionen.ClearSelection()
dgvUSTVPositionen.Rows(posIndex).Selected = True dgvUSTVPositionen.Rows(idx).Selected = True
For Each c As DataGridViewCell In dgvUSTVPositionen.Rows(posIndex).Cells For Each c As DataGridViewCell In dgvUSTVPositionen.Rows(idx).Cells
If c.Visible Then If c.Visible Then
dgvUSTVPositionen.CurrentCell = c 'Damit der Cursor in der DGV richtig steht dgvUSTVPositionen.CurrentCell = c
Exit For Exit For
End If End If
Next Next
End If End If
End If End If
suppressSelectionChanged = False
End Sub End Sub
Sub setValue(USTV_ANTRAG As VERAG_PROG_ALLGEMEIN.cUSTVAntrag) Sub setValue(USTV_ANTRAG As VERAG_PROG_ALLGEMEIN.cUSTVAntrag)
@@ -510,7 +514,6 @@ Public Class frmMDM_USTVAntrag
End Sub End Sub
Private Sub UsrCntlDatenDetails1_Changed(POSId) Handles UstCntlUSTV_AntragPosition1.CHANGED Private Sub UsrCntlDatenDetails1_Changed(POSId) Handles UstCntlUSTV_AntragPosition1.CHANGED
'refreshDgv(kdNr, SDLNr, Kfz, History)'?????????????? ausgebelndet,was das ein VErsuch? 31.07.2017
Dim posIdinDGV As Boolean = False Dim posIdinDGV As Boolean = False
@@ -2080,6 +2083,7 @@ Public Class frmMDM_USTVAntrag
Private Sub dgvUSTVPositionen_SelectionChanged(sender As Object, e As EventArgs) Handles dgvUSTVPositionen.SelectionChanged Private Sub dgvUSTVPositionen_SelectionChanged(sender As Object, e As EventArgs) Handles dgvUSTVPositionen.SelectionChanged
If suppressSelectionChanged Then Exit Sub
If dgvUSTVPositionen.SelectedRows.Count > 0 Then If dgvUSTVPositionen.SelectedRows.Count > 0 Then
initPosition(dgvUSTVPositionen.SelectedRows(0).Cells("UStVPo_ID").Value) initPosition(dgvUSTVPositionen.SelectedRows(0).Cells("UStVPo_ID").Value)
@@ -3150,7 +3154,7 @@ Public Class frmMDM_USTVAntrag
USTV_POS.UStVPo_Zeitstempel = Now() USTV_POS.UStVPo_Zeitstempel = Now()
If USTV_POS.SAVE() Then If USTV_POS.SAVE() Then
init() init()
'dgvUSTVPositionen.SetOrder() dgvUSTVPositionen.SetOrder()
Else Else
End If End If
@@ -3387,7 +3391,7 @@ Public Class frmMDM_USTVAntrag
If UStVAn_ID <= 0 Then Exit Sub If UStVAn_ID <= 0 Then Exit Sub
.SET_SQL("SELECT [UStVAn_ID] ,[UStVEr_ID],[UStVEr_USteuerbetragEUR],[Belegdatum],[Belegnummer],[GutschriftsDatum],[GutschriftsNr],UStVEr_VZ,UStVEr_RZVZ,UStVEr_Bank,UStVEr_Differenz,[Berufungsdatum],[Berufungshöhe],[Berufungsgrund],[Bemerkung],[UStVEr_Umrechnungskurs],[UStVEr_USteuerbetrag],[UStVEr_Sachbearbeiter],[UStVEr_Zeitstempel] .SET_SQL("SELECT [UStVAn_ID] ,[UStVEr_ID],[UStVEr_USteuerbetragEUR],[Belegdatum],[Belegnummer],[GutschriftsDatum],[GutschriftsNr],UStVEr_VZ,UStVEr_RZVZ,UStVEr_Bank,UStVEr_Differenz,[Berufungsdatum],[Berufungshöhe],[Berufungsgrund],[Bemerkung],[UStVEr_Umrechnungskurs],[UStVEr_USteuerbetrag],[UStVEr_Sachbearbeiter],[UStVEr_Zeitstempel],[UStVEr_RK_ID]
FROM [tblUStVErstattung] FROM [tblUStVErstattung]
where UStVAn_ID=" & UStVAn_ID & " ORDER BY UStVEr_ID", "FMZOLL") where UStVAn_ID=" & UStVAn_ID & " ORDER BY UStVEr_ID", "FMZOLL")
.LOAD() .LOAD()
@@ -3404,6 +3408,9 @@ Public Class frmMDM_USTVAntrag
.Columns("Belegdatum").Width = 80 .Columns("Belegdatum").Width = 80
.Columns("Belegnummer").Width = 130 .Columns("Belegnummer").Width = 130
.Columns("Belegdatum").Visible = False
.Columns("Belegnummer").Visible = False
.Columns("UStVEr_USteuerbetrag").HeaderText = "USt-Betrag" .Columns("UStVEr_USteuerbetrag").HeaderText = "USt-Betrag"
.Columns("UStVEr_USteuerbetrag").Width = 110 .Columns("UStVEr_USteuerbetrag").Width = 110
.Columns("UStVEr_USteuerbetrag").DefaultCellStyle.Format = "N2" .Columns("UStVEr_USteuerbetrag").DefaultCellStyle.Format = "N2"
@@ -3447,8 +3454,8 @@ Public Class frmMDM_USTVAntrag
.Columns("Berufungsgrund").Width = 100 .Columns("Berufungsgrund").Width = 100
.Columns("Bemerkung").Width = 200 .Columns("Bemerkung").Width = 200
.Columns("UStVEr_Umrechnungskurs").HeaderText = "Umrechnungskurs" .Columns("UStVEr_Umrechnungskurs").HeaderText = "Kurs"
.Columns("UStVEr_Umrechnungskurs").Width = 60 .Columns("UStVEr_Umrechnungskurs").Width = 30
.Columns("UStVEr_Umrechnungskurs").DefaultCellStyle.Format = "N2" .Columns("UStVEr_Umrechnungskurs").DefaultCellStyle.Format = "N2"
.Columns("UStVEr_Umrechnungskurs").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleRight .Columns("UStVEr_Umrechnungskurs").DefaultCellStyle.Alignment = DataGridViewContentAlignment.MiddleRight
@@ -3462,9 +3469,40 @@ Public Class frmMDM_USTVAntrag
.Columns("UStVEr_Sachbearbeiter").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill .Columns("UStVEr_Sachbearbeiter").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill
.Columns("UStVEr_Zeitstempel").Visible = False .Columns("UStVEr_Zeitstempel").Visible = False
.Columns("UStVEr_RK_ID").Visible = False
End If End If
Dim c As New DataGridViewImageColumn
c.Name = "clmnPDF" : c.HeaderText = "GU"
' c.Image = Nothing
c.DefaultCellStyle.NullValue = Nothing
c.ImageLayout = DataGridViewImageCellLayout.Zoom
c.Width = 40 : c.DefaultCellStyle.Padding = New Padding(2) : c.DefaultCellStyle.BackColor = Color.White
'c.DefaultCellStyle.Tag = "Therefore anzeigen"
If Not .Columns.Contains("clmnPDF") Then .Columns.Add(c)
For Each r As DataGridViewRow In .Rows
Dim rk_id As Integer = -1
If Not IsDBNull(r.Cells("UStVEr_RK_ID").Value) Then
rk_id = r.Cells("UStVEr_RK_ID").Value
End If
If rk_id > 0 Then
DirectCast(r.Cells("clmnPDF"), DataGridViewImageCell).Value = Nothing
DirectCast(r.Cells("clmnPDF"), DataGridViewImageCell).Value = My.Resources.pdf
End If
Next
If .RowCount < 1 Then If .RowCount < 1 Then
initErstsattungsPosition(-1) initErstsattungsPosition(-1)
@@ -3474,9 +3512,9 @@ Public Class frmMDM_USTVAntrag
If posIndex > 0 And dgvErstattungspositionen.Rows.Count > posIndex Then If posIndex > 0 And dgvErstattungspositionen.Rows.Count > posIndex Then
dgvErstattungspositionen.ClearSelection() dgvErstattungspositionen.ClearSelection()
dgvErstattungspositionen.Rows(posIndex).Selected = True dgvErstattungspositionen.Rows(posIndex).Selected = True
For Each c As DataGridViewCell In dgvErstattungspositionen.Rows(posIndex).Cells For Each co As DataGridViewCell In dgvErstattungspositionen.Rows(posIndex).Cells
If c.Visible Then If co.Visible Then
dgvErstattungspositionen.CurrentCell = c 'Damit der Cursor in der DGV richtig steht dgvErstattungspositionen.CurrentCell = co 'Damit der Cursor in der DGV richtig steht
Exit For Exit For
End If End If
Next Next
@@ -5423,6 +5461,28 @@ Public Class frmMDM_USTVAntrag
End Sub End Sub
Private Sub dgvErstattungspositionen_CellContentDoubleClick(sender As Object, e As DataGridViewCellEventArgs) Handles dgvErstattungspositionen.CellContentDoubleClick
Try
If e.RowIndex >= 0 AndAlso e.ColumnIndex >= 0 Then
Dim pdf As String = ""
pdf = func.getPDF(1, Nothing, Nothing, dgvErstattungspositionen.Rows(e.RowIndex).Cells("UStVEr_RK_ID").Value, False, False, Antrag_LandKz, USTV_ANTRAG, New cFakturierung, False)
If System.IO.File.Exists(pdf) Then
Process.Start(pdf)
End If
End If
Catch ex As Exception
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodInfo.GetCurrentMethod.Name)
Me.Cursor = Cursors.Default
End Try
Me.Cursor = Cursors.Default
End Sub
Public Shared Function rearangePosNrByLeistender(UStVAn_ID As Integer) Public Shared Function rearangePosNrByLeistender(UStVAn_ID As Integer)

View File

@@ -2065,8 +2065,8 @@ Public Class usrCntlUSTV
.btnPreisliste.Visible = False .btnPreisliste.Visible = False
.dgvHandling.RowHeadersVisible = False .dgvHandling.RowHeadersVisible = False
.Button2.Text = "Importieren" .Button2.Text = "Importieren"
.cbxDivers.Visible = True '.cbxDivers.Visible = True
.cbxDivers.Text = "VZ und RZ-Beträge im Antrag erhöhen" '.cbxDivers.Text = "VZ und RZ-Beträge im Antrag erhöhen"
End With End With
frm.ShowDialog() frm.ShowDialog()
@@ -2087,7 +2087,7 @@ Public Class usrCntlUSTV
Dim updateVURZ As Boolean = False Dim updateVURZ As Boolean = False
updateVURZ = frm.cbxDivers.Checked updateVURZ = False 'frm.cbxDivers.Checked
Dim UStV_ERS = New VERAG_PROG_ALLGEMEIN.cUStVErstattungPositionen(Belegdatum, BelegNr, fd.SafeFileName) Dim UStV_ERS = New VERAG_PROG_ALLGEMEIN.cUStVErstattungPositionen(Belegdatum, BelegNr, fd.SafeFileName)
If Not UStV_ERS.hasEntry Then If Not UStV_ERS.hasEntry Then

View File

@@ -87,11 +87,12 @@ Public Class ustCntlUSTV_AntragPosition
sbLeistender._value = UStV_Leitender.UStV_LeistenderId sbLeistender._value = UStV_Leitender.UStV_LeistenderId
sbLeistender_VALUE_CHANGED() sbLeistender_VALUE_CHANGED()
Else Else
sbLeistender._value = "" 'sbLeistender._value = ""
End If End If
sbLeistender._value = "" 'sbLeistender._value = ""
Else Else
sbLeistender._value = "" sbLeistender._value = ""
sbLeistender.Text = ""
End If End If

View File

@@ -604,6 +604,7 @@ Public Class cUStVErstattungPositionen
Property UStVEr_RZVZ As Object = Nothing Property UStVEr_RZVZ As Object = Nothing
Property UStVEr_Bank As Object = Nothing Property UStVEr_Bank As Object = Nothing
Property UStVEr_Differenz As Object = Nothing Property UStVEr_Differenz As Object = Nothing
Property UStVEr_RK_ID As Object = Nothing
Public hasEntry = False Public hasEntry = False
@@ -635,10 +636,11 @@ Public Class cUStVErstattungPositionen
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_RZVZ", UStVEr_RZVZ)) list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_RZVZ", UStVEr_RZVZ))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_Bank", UStVEr_Bank)) list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_Bank", UStVEr_Bank))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_Differenz", UStVEr_Differenz)) list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_Differenz", UStVEr_Differenz))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("UStVEr_RK_ID", UStVEr_RK_ID))
Return list Return list
End Function End Function
Sub New(Belegdatum, Belegnummer, UStVEr_Importfilename) Sub New(Belegdatum As Date, Belegnummer As Integer, UStVEr_Importfilename As String)
Me.Belegdatum = Belegdatum Me.Belegdatum = Belegdatum
Me.Belegnummer = Belegnummer Me.Belegnummer = Belegnummer
Me.UStVEr_Importfilename = UStVEr_Importfilename Me.UStVEr_Importfilename = UStVEr_Importfilename
@@ -647,18 +649,26 @@ Public Class cUStVErstattungPositionen
End Sub End Sub
Sub New(UStVAn_ID, UStVEr_ID) Sub New(UStVAn_ID As Integer, UStVEr_ID As Integer)
Me.UStVAn_ID = UStVAn_ID Me.UStVAn_ID = UStVAn_ID
Me.UStVEr_ID = UStVEr_ID Me.UStVEr_ID = UStVEr_ID
LOAD(UStVAn_ID, UStVEr_ID) LOAD(UStVAn_ID, UStVEr_ID)
End Sub End Sub
Sub New(UStVAn_ID As Integer, GutschriftsNr As Integer, GutschriftsDatum As Date)
Me.UStVAn_ID = UStVAn_ID
Me.GutschriftsNr = GutschriftsNr
Me.GutschriftsDatum = GutschriftsDatum
LOAD(UStVAn_ID, GutschriftsDatum, GutschriftsNr)
End Sub
Sub New() Sub New()
End Sub End Sub
Public Sub LOAD(UStVAn_ID, UStVEr_ID) Public Sub LOAD(UStVAn_ID As Integer, UStVEr_ID As Integer)
Try Try
hasEntry = False hasEntry = False
@@ -688,7 +698,7 @@ Public Class cUStVErstattungPositionen
End Try End Try
End Sub End Sub
Public Sub LOAD(Belegdatum, Belegnummer, UStVEr_Importfilename) Public Sub LOAD(Belegdatum As Date, Belegnummer As Integer, UStVEr_Importfilename As String)
Try Try
hasEntry = False hasEntry = False
@@ -719,6 +729,37 @@ Public Class cUStVErstattungPositionen
End Try End Try
End Sub End Sub
Public Sub LOAD(UStVAn_ID As Integer, GutschriftsDatum As Date, GutschriftNr As Integer)
Try
hasEntry = False
Using conn As SqlConnection = SQL.GetNewOpenConnectionFMZOLL()
Using cmd As New SqlCommand("SELECT * FROM tblUStVErstattung WHERE GutschriftsDatum=@GutschriftsDatum AND GutschriftsNr=@GutschriftsNr AND UStVAn_ID=@UStVAn_ID ", conn)
cmd.Parameters.AddWithValue("@GutschriftsDatum", GutschriftsDatum)
cmd.Parameters.AddWithValue("@GutschriftsNr", GutschriftsNr)
cmd.Parameters.AddWithValue("@UStVAn_ID", UStVAn_ID)
Dim dr = cmd.ExecuteReader()
If dr.Read Then
'Dim l As New cOfferte
For Each i In getParameterList()
Dim propInfo As PropertyInfo = Me.GetType.GetProperty(i.Scalarvariable)
If dr.Item(i.Text) Is DBNull.Value Then
propInfo.SetValue(Me, Nothing)
Else
propInfo.SetValue(Me, dr.Item(i.Text))
End If
Next
hasEntry = True
End If
dr.Close()
End Using
End Using
Catch ex As Exception
MsgBox("Fehler in der Funktion '" & System.Reflection.MethodInfo.GetCurrentMethod.Name & "'" & vbNewLine & vbNewLine & ex.Message & vbNewLine & vbNewLine & ex.StackTrace)
End Try
End Sub
Public Function SAVE() As Boolean Public Function SAVE() As Boolean
Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList() Dim list As List(Of VERAG_PROG_ALLGEMEIN.SQLVariable) = getParameterList()