CBAM
This commit is contained in:
@@ -293,8 +293,8 @@ Public Class usrcntlVorauskasse
|
|||||||
If cboFirma._value <> "" Then
|
If cboFirma._value <> "" Then
|
||||||
Dim FIRMA_TMP = New VERAG_PROG_ALLGEMEIN.cFirmen(cboFirma._value)
|
Dim FIRMA_TMP = New VERAG_PROG_ALLGEMEIN.cFirmen(cboFirma._value)
|
||||||
' MsgBox(FIRMA_TMP.Firma_LandKz)
|
' MsgBox(FIRMA_TMP.Firma_LandKz)
|
||||||
Select Case If(txtUid.Text > 2, txtUid.Text, If(FIRMA_TMP.Firma_LandKz = "A", "AT", FIRMA_TMP.Firma_LandKz))
|
Select Case FIRMA_TMP.Firma_LandKz 'If (txtUid.Text.Length > 2, txtUid.Text, If(FIRMA_TMP.Firma_LandKz = "A", "AT", FIRMA_TMP.Firma_LandKz)) Then
|
||||||
Case "AT"
|
Case "A", "AT"
|
||||||
If txtAdresse2.Text.StartsWith("TR") Or txtAdresse2.Text.StartsWith("SRB") Or txtAdresse2.Text.StartsWith("GB") Then
|
If txtAdresse2.Text.StartsWith("TR") Or txtAdresse2.Text.StartsWith("SRB") Or txtAdresse2.Text.StartsWith("GB") Then
|
||||||
txtMwstProzent._value = 0
|
txtMwstProzent._value = 0
|
||||||
ElseIf txtUid.Text.Trim = "" OrElse txtUid.Text.ToUpper.StartsWith("AT") Then
|
ElseIf txtUid.Text.Trim = "" OrElse txtUid.Text.ToUpper.StartsWith("AT") Then
|
||||||
|
|||||||
65
SDL/kunden/usrCntlCBAM.Designer.vb
generated
65
SDL/kunden/usrCntlCBAM.Designer.vb
generated
@@ -99,8 +99,10 @@ Partial Class usrCntlCBAM
|
|||||||
Me.Label18 = New System.Windows.Forms.Label()
|
Me.Label18 = New System.Windows.Forms.Label()
|
||||||
Me.Label19 = New System.Windows.Forms.Label()
|
Me.Label19 = New System.Windows.Forms.Label()
|
||||||
Me.TextBox1 = New System.Windows.Forms.TextBox()
|
Me.TextBox1 = New System.Windows.Forms.TextBox()
|
||||||
Me.Button8 = New System.Windows.Forms.Button()
|
Me.btnVERAGCost = New System.Windows.Forms.Button()
|
||||||
Me.cbxVERAG_GPXLS = New System.Windows.Forms.CheckBox()
|
Me.cbxVERAG_GPXLS = New System.Windows.Forms.CheckBox()
|
||||||
|
Me.cbxIndirekt = New System.Windows.Forms.CheckBox()
|
||||||
|
Me.cboIndirekt = New VERAG_PROG_ALLGEMEIN.MyComboBox()
|
||||||
Me.txtCalc_Defaut_Country = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
Me.txtCalc_Defaut_Country = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||||
Me.MyTextBox3 = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
Me.MyTextBox3 = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||||
Me.txtCalc_Defaut_Year = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
Me.txtCalc_Defaut_Year = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||||
@@ -999,9 +1001,9 @@ Partial Class usrCntlCBAM
|
|||||||
Me.Label19.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Underline, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
Me.Label19.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Underline, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||||
Me.Label19.Location = New System.Drawing.Point(3, 3)
|
Me.Label19.Location = New System.Drawing.Point(3, 3)
|
||||||
Me.Label19.Name = "Label19"
|
Me.Label19.Name = "Label19"
|
||||||
Me.Label19.Size = New System.Drawing.Size(173, 13)
|
Me.Label19.Size = New System.Drawing.Size(174, 13)
|
||||||
Me.Label19.TabIndex = 53
|
Me.Label19.TabIndex = 53
|
||||||
Me.Label19.Text = "CBAM-Rechner (ohne Emissionen):"
|
Me.Label19.Text = "CBAM-Rechner (ohne Benchmark):"
|
||||||
'
|
'
|
||||||
'TextBox1
|
'TextBox1
|
||||||
'
|
'
|
||||||
@@ -1016,18 +1018,18 @@ Partial Class usrCntlCBAM
|
|||||||
Me.TextBox1.TabIndex = 69
|
Me.TextBox1.TabIndex = 69
|
||||||
Me.TextBox1.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
|
Me.TextBox1.TextAlign = System.Windows.Forms.HorizontalAlignment.Right
|
||||||
'
|
'
|
||||||
'Button8
|
'btnVERAGCost
|
||||||
'
|
'
|
||||||
Me.Button8.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
Me.btnVERAGCost.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||||
Me.Button8.Image = Global.SDL.My.Resources.Resources.moneybag1
|
Me.btnVERAGCost.Image = Global.SDL.My.Resources.Resources.moneybag1
|
||||||
Me.Button8.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
Me.btnVERAGCost.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||||
Me.Button8.Location = New System.Drawing.Point(106, 603)
|
Me.btnVERAGCost.Location = New System.Drawing.Point(106, 603)
|
||||||
Me.Button8.Name = "Button8"
|
Me.btnVERAGCost.Name = "btnVERAGCost"
|
||||||
Me.Button8.Size = New System.Drawing.Size(168, 42)
|
Me.btnVERAGCost.Size = New System.Drawing.Size(168, 42)
|
||||||
Me.Button8.TabIndex = 70
|
Me.btnVERAGCost.TabIndex = 70
|
||||||
Me.Button8.Text = "Kosten ermitteln"
|
Me.btnVERAGCost.Text = "Kosten ermitteln"
|
||||||
Me.Button8.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
Me.btnVERAGCost.TextAlign = System.Drawing.ContentAlignment.MiddleRight
|
||||||
Me.Button8.UseVisualStyleBackColor = True
|
Me.btnVERAGCost.UseVisualStyleBackColor = True
|
||||||
'
|
'
|
||||||
'cbxVERAG_GPXLS
|
'cbxVERAG_GPXLS
|
||||||
'
|
'
|
||||||
@@ -1038,6 +1040,30 @@ Partial Class usrCntlCBAM
|
|||||||
Me.cbxVERAG_GPXLS.TabIndex = 3
|
Me.cbxVERAG_GPXLS.TabIndex = 3
|
||||||
Me.cbxVERAG_GPXLS.UseVisualStyleBackColor = True
|
Me.cbxVERAG_GPXLS.UseVisualStyleBackColor = True
|
||||||
'
|
'
|
||||||
|
'cbxIndirekt
|
||||||
|
'
|
||||||
|
Me.cbxIndirekt.AutoSize = True
|
||||||
|
Me.cbxIndirekt.Location = New System.Drawing.Point(106, 30)
|
||||||
|
Me.cbxIndirekt.Name = "cbxIndirekt"
|
||||||
|
Me.cbxIndirekt.Size = New System.Drawing.Size(77, 17)
|
||||||
|
Me.cbxIndirekt.TabIndex = 3
|
||||||
|
Me.cbxIndirekt.Text = "INDIREKT"
|
||||||
|
Me.cbxIndirekt.UseVisualStyleBackColor = True
|
||||||
|
'
|
||||||
|
'cboIndirekt
|
||||||
|
'
|
||||||
|
Me.cboIndirekt._allowedValuesFreiText = Nothing
|
||||||
|
Me.cboIndirekt._allowFreiText = False
|
||||||
|
Me.cboIndirekt._value = ""
|
||||||
|
Me.cboIndirekt.DropDownWidth = 350
|
||||||
|
Me.cboIndirekt.FormattingEnabled = True
|
||||||
|
Me.cboIndirekt.Items.AddRange(New Object() {"", "Q1", "Q2", "Q3", "Q4"})
|
||||||
|
Me.cboIndirekt.Location = New System.Drawing.Point(106, 48)
|
||||||
|
Me.cboIndirekt.Name = "cboIndirekt"
|
||||||
|
Me.cboIndirekt.Size = New System.Drawing.Size(341, 21)
|
||||||
|
Me.cboIndirekt.TabIndex = 71
|
||||||
|
Me.cboIndirekt.Visible = False
|
||||||
|
'
|
||||||
'txtCalc_Defaut_Country
|
'txtCalc_Defaut_Country
|
||||||
'
|
'
|
||||||
Me.txtCalc_Defaut_Country._DateTimeOnly = False
|
Me.txtCalc_Defaut_Country._DateTimeOnly = False
|
||||||
@@ -1194,7 +1220,6 @@ Partial Class usrCntlCBAM
|
|||||||
Me.cbo_VERAG_ImpLand._allowFreiText = False
|
Me.cbo_VERAG_ImpLand._allowFreiText = False
|
||||||
Me.cbo_VERAG_ImpLand._value = ""
|
Me.cbo_VERAG_ImpLand._value = ""
|
||||||
Me.cbo_VERAG_ImpLand.FormattingEnabled = True
|
Me.cbo_VERAG_ImpLand.FormattingEnabled = True
|
||||||
Me.cbo_VERAG_ImpLand.Items.AddRange(New Object() {"", "Q1", "Q2", "Q3", "Q4"})
|
|
||||||
Me.cbo_VERAG_ImpLand.Location = New System.Drawing.Point(106, 169)
|
Me.cbo_VERAG_ImpLand.Location = New System.Drawing.Point(106, 169)
|
||||||
Me.cbo_VERAG_ImpLand.Name = "cbo_VERAG_ImpLand"
|
Me.cbo_VERAG_ImpLand.Name = "cbo_VERAG_ImpLand"
|
||||||
Me.cbo_VERAG_ImpLand.Size = New System.Drawing.Size(168, 21)
|
Me.cbo_VERAG_ImpLand.Size = New System.Drawing.Size(168, 21)
|
||||||
@@ -1379,7 +1404,7 @@ Partial Class usrCntlCBAM
|
|||||||
Me.MyPanel1.Controls.Add(Me.cbxUNISPED)
|
Me.MyPanel1.Controls.Add(Me.cbxUNISPED)
|
||||||
Me.MyPanel1.Controls.Add(Me.cbxIMEX)
|
Me.MyPanel1.Controls.Add(Me.cbxIMEX)
|
||||||
Me.MyPanel1.Controls.Add(Me.cbxVERAG)
|
Me.MyPanel1.Controls.Add(Me.cbxVERAG)
|
||||||
Me.MyPanel1.Location = New System.Drawing.Point(98, 4)
|
Me.MyPanel1.Location = New System.Drawing.Point(453, 4)
|
||||||
Me.MyPanel1.Name = "MyPanel1"
|
Me.MyPanel1.Name = "MyPanel1"
|
||||||
Me.MyPanel1.Size = New System.Drawing.Size(590, 28)
|
Me.MyPanel1.Size = New System.Drawing.Size(590, 28)
|
||||||
Me.MyPanel1.TabIndex = 39
|
Me.MyPanel1.TabIndex = 39
|
||||||
@@ -1523,8 +1548,10 @@ Partial Class usrCntlCBAM
|
|||||||
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
|
||||||
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
|
||||||
Me.BackColor = System.Drawing.Color.White
|
Me.BackColor = System.Drawing.Color.White
|
||||||
|
Me.Controls.Add(Me.cboIndirekt)
|
||||||
|
Me.Controls.Add(Me.cbxIndirekt)
|
||||||
Me.Controls.Add(Me.cbxVERAG_GPXLS)
|
Me.Controls.Add(Me.cbxVERAG_GPXLS)
|
||||||
Me.Controls.Add(Me.Button8)
|
Me.Controls.Add(Me.btnVERAGCost)
|
||||||
Me.Controls.Add(Me.cbxKosten)
|
Me.Controls.Add(Me.cbxKosten)
|
||||||
Me.Controls.Add(Me.TextBox1)
|
Me.Controls.Add(Me.TextBox1)
|
||||||
Me.Controls.Add(Me.Panel2)
|
Me.Controls.Add(Me.Panel2)
|
||||||
@@ -1706,6 +1733,8 @@ Partial Class usrCntlCBAM
|
|||||||
Friend WithEvents txtCalc_Defaut_KN8 As VERAG_PROG_ALLGEMEIN.MyTextBox
|
Friend WithEvents txtCalc_Defaut_KN8 As VERAG_PROG_ALLGEMEIN.MyTextBox
|
||||||
Friend WithEvents Label19 As Label
|
Friend WithEvents Label19 As Label
|
||||||
Friend WithEvents TextBox1 As TextBox
|
Friend WithEvents TextBox1 As TextBox
|
||||||
Friend WithEvents Button8 As Button
|
Friend WithEvents btnVERAGCost As Button
|
||||||
Friend WithEvents cbxVERAG_GPXLS As CheckBox
|
Friend WithEvents cbxVERAG_GPXLS As CheckBox
|
||||||
|
Friend WithEvents cboIndirekt As VERAG_PROG_ALLGEMEIN.MyComboBox
|
||||||
|
Friend WithEvents cbxIndirekt As CheckBox
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -420,6 +420,16 @@ Public Class usrCntlCBAM
|
|||||||
txtEori.Text = KD.EORITIN
|
txtEori.Text = KD.EORITIN
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
cboIndirekt.Items.Clear()
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("VERAG Spedition GmbH - DE4824105", "DE4824105"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("VERAG Customs Service GmbH - ATEOS1000059121", "DE4ATEOS1000059121824105"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("VERAG Zollservice GmbH - ATEOS1000000200", "ATEOS1000000200"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("VERAG Spedition AG - ATEOS1000000199", "ATEOS1000000199"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("IMEX Customs Service GmbH - ATEOS1000059735", "ATEOS1000059735"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("UNISPED Speditions GmbH - ATEOS1000000088", "ATEOS1000000088"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("UNISPED Zollservice GmbH - ATEOS1000040508", "ATEOS1000040508"))
|
||||||
|
cboIndirekt.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("UNISPED Deutschland GmbH - DE7467540", "DE7467540"))
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub cboQuartal_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cboQuartal.SelectedIndexChanged
|
Private Sub cboQuartal_SelectedIndexChanged(sender As Object, e As EventArgs) Handles cboQuartal.SelectedIndexChanged
|
||||||
@@ -2159,16 +2169,16 @@ Public Class usrCntlCBAM
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click
|
Private Sub Button6_Click(sender As Object, e As EventArgs) Handles Button6.Click
|
||||||
Dim EORI = txtEori.Text
|
Dim EORI = {txtEori.Text}
|
||||||
If cbxVERAG.Checked Then EORI = "VERAG"
|
If cbxIndirekt.Checked Then EORI = {cboIndirekt._value}
|
||||||
If EORI = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
If EORI(0) = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
||||||
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
||||||
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
||||||
|
|
||||||
lblErg_VERAG.Text = "-"
|
lblErg_VERAG.Text = "-"
|
||||||
lblErg_VERAG2.Text = "-"
|
lblErg_VERAG2.Text = "-"
|
||||||
|
|
||||||
Dim LIST = VERAG_PROG_ALLGEMEIN.cVERAG_CustomsDeclarations.LOAD_List_CBAM(txtEori.Text, "", txtVon._value, txtBis._value,, False)
|
Dim LIST = VERAG_PROG_ALLGEMEIN.cVERAG_CustomsDeclarations.LOAD_List_CBAM(EORI, "", txtVon._value, txtBis._value,, False)
|
||||||
|
|
||||||
cbo_VERAG_ImpLand.Items.Clear()
|
cbo_VERAG_ImpLand.Items.Clear()
|
||||||
|
|
||||||
@@ -2179,10 +2189,13 @@ Public Class usrCntlCBAM
|
|||||||
Distinct().
|
Distinct().
|
||||||
OrderBy(Function(c) c).
|
OrderBy(Function(c) c).
|
||||||
ToList()
|
ToList()
|
||||||
|
cbo_VERAG_ImpLand.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem("", ""))
|
||||||
For Each c In countries
|
For Each c In countries
|
||||||
cbo_VERAG_ImpLand.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(c, c))
|
cbo_VERAG_ImpLand.Items.Add(New VERAG_PROG_ALLGEMEIN.MyListItem(c, c))
|
||||||
Next
|
Next
|
||||||
|
If cbo_VERAG_ImpLand.Items.Count = 2 Then
|
||||||
|
cbo_VERAG_ImpLand.SelectedIndex = 1
|
||||||
|
End If
|
||||||
|
|
||||||
lblErg_VERAG.Text = LIST.Count
|
lblErg_VERAG.Text = LIST.Count
|
||||||
lblErg_VERAG2.Text = String.Join(", ", countries)
|
lblErg_VERAG2.Text = String.Join(", ", countries)
|
||||||
@@ -2191,12 +2204,12 @@ Public Class usrCntlCBAM
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub Button16_Click(sender As Object, e As EventArgs) Handles btnCBAM_DS_VERAG.Click
|
Private Sub Button16_Click(sender As Object, e As EventArgs) Handles btnCBAM_DS_VERAG.Click
|
||||||
Dim EORI = txtEori.Text
|
Dim EORI = {txtEori.Text}
|
||||||
If cbxVERAG.Checked Then EORI = "VERAG"
|
If cbxIndirekt.Checked Then EORI = {cboIndirekt._value}
|
||||||
If EORI = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
If EORI(0) = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
||||||
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
||||||
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
||||||
If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub :
|
If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub :
|
||||||
Me.Cursor = Cursors.WaitCursor
|
Me.Cursor = Cursors.WaitCursor
|
||||||
Try
|
Try
|
||||||
|
|
||||||
@@ -2206,9 +2219,9 @@ Public Class usrCntlCBAM
|
|||||||
TextBox1.Text = LIST.Count
|
TextBox1.Text = LIST.Count
|
||||||
|
|
||||||
|
|
||||||
doVERAG_SUM(LIST, EORI)
|
doVERAG_SUM(LIST, EORI(0))
|
||||||
doVERAG_DETAIL(LIST, EORI)
|
doVERAG_DETAIL(LIST, EORI(0))
|
||||||
If cbxVERAG_GPXLS.Checked Then doVERAG_GREENPULSE_XLS(LIST, EORI)
|
If cbxVERAG_GPXLS.Checked Then doVERAG_GREENPULSE_XLS(LIST, EORI(0))
|
||||||
|
|
||||||
|
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
@@ -2272,10 +2285,10 @@ Public Class usrCntlCBAM
|
|||||||
r.VorangegangenesVerfahren
|
r.VorangegangenesVerfahren
|
||||||
)
|
)
|
||||||
|
|
||||||
MsgBox(r.Tarifnummer)
|
' MsgBox(r.Tarifnummer)
|
||||||
Next
|
Next
|
||||||
|
|
||||||
MsgBox(dt.Rows.Count)
|
' MsgBox(dt.Rows.Count)
|
||||||
|
|
||||||
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
|
If dt IsNot Nothing AndAlso dt.Rows.Count > 0 Then
|
||||||
Dim path = VERAG_PROG_ALLGEMEIN.cProgramFunctions.genExcelFromDT_NEW(dt,, , , , False, EORI & "_Summenbericht_" & txtVon._value & "-" & txtBis._value)
|
Dim path = VERAG_PROG_ALLGEMEIN.cProgramFunctions.genExcelFromDT_NEW(dt,, , , , False, EORI & "_Summenbericht_" & txtVon._value & "-" & txtBis._value)
|
||||||
@@ -2574,9 +2587,9 @@ Public Class usrCntlCBAM
|
|||||||
|
|
||||||
|
|
||||||
Try
|
Try
|
||||||
Dim EORI = txtEori.Text
|
Dim EORI = {txtEori.Text}
|
||||||
If cbxVERAG.Checked Then EORI = "VERAG"
|
If cbxIndirekt.Checked Then EORI = {cboIndirekt._value}
|
||||||
If EORI = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
If EORI(0) = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
||||||
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
||||||
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
||||||
If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub
|
If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub
|
||||||
@@ -2643,7 +2656,7 @@ Public Class usrCntlCBAM
|
|||||||
|
|
||||||
|
|
||||||
If dt.Rows.Count > 0 Then
|
If dt.Rows.Count > 0 Then
|
||||||
doCBAM_XML(dt, EORI)
|
doCBAM_XML(dt, EORI(0))
|
||||||
Button2.Enabled = True
|
Button2.Enabled = True
|
||||||
btnCBAM_DS_VERAG_XML.Enabled = True
|
btnCBAM_DS_VERAG_XML.Enabled = True
|
||||||
End If
|
End If
|
||||||
@@ -2662,9 +2675,9 @@ Public Class usrCntlCBAM
|
|||||||
Private Sub btnCBAM_DS_VERAG_SendToGreenpulse_Click(sender As Object, e As EventArgs) Handles btnCBAM_DS_VERAG_SendToGreenpulse.Click
|
Private Sub btnCBAM_DS_VERAG_SendToGreenpulse_Click(sender As Object, e As EventArgs) Handles btnCBAM_DS_VERAG_SendToGreenpulse.Click
|
||||||
|
|
||||||
Try
|
Try
|
||||||
Dim EORI = txtEori.Text
|
Dim EORI = {txtEori.Text}
|
||||||
If cbxVERAG.Checked Then EORI = "VERAG"
|
If cbxIndirekt.Checked Then EORI = {cboIndirekt._value}
|
||||||
If EORI = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
If EORI(0) = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
||||||
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
||||||
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
||||||
If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub
|
If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub
|
||||||
@@ -2714,16 +2727,22 @@ Public Class usrCntlCBAM
|
|||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub Button8_Click(sender As Object, e As EventArgs) Handles Button8.Click
|
Private Sub Button8_Click(sender As Object, e As EventArgs) Handles btnVERAGCost.Click
|
||||||
Dim EORI = txtEori.Text
|
Dim EORI = {txtEori.Text}
|
||||||
If cbxVERAG.Checked Then EORI = "VERAG"
|
If cbxIndirekt.Checked Then EORI = {cboIndirekt._value}
|
||||||
If EORI = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
If EORI(0) = "" Then MsgBox("EORI eingeben!") : Exit Sub
|
||||||
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
If txtVon._value = "" Then MsgBox("Datum von eingeben!") : Exit Sub
|
||||||
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
If txtBis._value = "" Then MsgBox("Datum bis eingeben!") : Exit Sub
|
||||||
'If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub
|
'If cbo_VERAG_ImpLand._value = "" Then MsgBox("Importland auswählen!") : Exit Sub
|
||||||
|
|
||||||
Me.Cursor = Cursors.WaitCursor
|
Me.Cursor = Cursors.WaitCursor
|
||||||
|
|
||||||
|
Dim SQLSTR_WHERE_FIRMEN = ""
|
||||||
|
If cbxVERAG.Checked Then SQLSTR_WHERE_FIRMEN &= "'SUB','WAI','SBG','NKD','NEU','AMBWO','AMB','IRU','EXP','SUW','DUR'"
|
||||||
|
If cbxIMEX.Checked Then SQLSTR_WHERE_FIRMEN &= IIf(SQLSTR_WHERE_FIRMEN <> "", ", ", "") & "'IME'"
|
||||||
|
If cbxUNISPED.Checked Then SQLSTR_WHERE_FIRMEN &= IIf(SQLSTR_WHERE_FIRMEN <> "", ", ", "") & "'ATSPED'" '???
|
||||||
|
|
||||||
|
|
||||||
Dim LIST As List(Of VERAG_PROG_ALLGEMEIN.cVERAG_CustomsDeclarations) = VERAG_PROG_ALLGEMEIN.cVERAG_CustomsDeclarations.LOAD_List_CBAM(EORI, cbo_VERAG_ImpLand._value, txtVon._value, txtBis._value,, True)
|
Dim LIST As List(Of VERAG_PROG_ALLGEMEIN.cVERAG_CustomsDeclarations) = VERAG_PROG_ALLGEMEIN.cVERAG_CustomsDeclarations.LOAD_List_CBAM(EORI, cbo_VERAG_ImpLand._value, txtVon._value, txtBis._value,, True)
|
||||||
|
|
||||||
|
|
||||||
@@ -2757,11 +2776,17 @@ Public Class usrCntlCBAM
|
|||||||
.Cells("clmnTarif").Value = g.Tarif
|
.Cells("clmnTarif").Value = g.Tarif
|
||||||
.Cells("clmnWeight").Value = eigMasse
|
.Cells("clmnWeight").Value = eigMasse
|
||||||
.Cells("clmnCountry").Value = g.Country
|
.Cells("clmnCountry").Value = g.Country
|
||||||
.Cells("clmnYear").Value = If(txtBis._value <> "", CDate(txtBis._value).Year, Now.Year)
|
.Cells("clmnYear").Value = If(txtBis._value <> "" AndAlso CDate(txtBis._value).Year >= 2026, CDate(txtBis._value).Year, Now.Year)
|
||||||
End With
|
End With
|
||||||
Next
|
Next
|
||||||
f.autocalc = True
|
f.autocalc = True
|
||||||
f.Show()
|
f.Show()
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Sub CheckBox1_CheckedChanged_1(sender As Object, e As EventArgs) Handles cbxIndirekt.CheckedChanged
|
||||||
|
cboIndirekt.Visible = cbxIndirekt.Checked
|
||||||
|
txtEori.Visible = Not cbxIndirekt.Checked
|
||||||
|
End Sub
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
|||||||
@@ -208,7 +208,7 @@ Public Class cVERAG_CustomsDeclarations
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
Public Shared Function LOAD_List_CBAM(EORI As String, ImportCountry As String, datFrom As Date, datTo As Date, Optional CustomsSystem As String = "", Optional loadAll As Boolean = True) As List(Of cVERAG_CustomsDeclarations)
|
Public Shared Function LOAD_List_CBAM(EORI() As String, ImportCountry As String, datFrom As Date, datTo As Date, Optional CustomsSystem As String = "", Optional loadAll As Boolean = True, Optional indirect As Boolean = False) As List(Of cVERAG_CustomsDeclarations)
|
||||||
|
|
||||||
Dim LIST As New List(Of cVERAG_CustomsDeclarations)
|
Dim LIST As New List(Of cVERAG_CustomsDeclarations)
|
||||||
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
|
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
|
||||||
@@ -222,6 +222,10 @@ Public Class cVERAG_CustomsDeclarations
|
|||||||
' ------------------------------------------------------------
|
' ------------------------------------------------------------
|
||||||
' SQL: ZA-IDs ermitteln
|
' SQL: ZA-IDs ermitteln
|
||||||
' ------------------------------------------------------------
|
' ------------------------------------------------------------
|
||||||
|
Dim eoriIn As String =
|
||||||
|
String.Join(",", EORI.
|
||||||
|
Where(Function(x) Not String.IsNullOrWhiteSpace(x)).
|
||||||
|
Select(Function(x) "'" & x.Replace("'", "''") & "'"))
|
||||||
Dim sqlstr As String =
|
Dim sqlstr As String =
|
||||||
"SELECT DISTINCT z.* " &
|
"SELECT DISTINCT z.* " &
|
||||||
"FROM VERAG.dbo.tblVERAG_CustomsDeclarations z " &
|
"FROM VERAG.dbo.tblVERAG_CustomsDeclarations z " &
|
||||||
@@ -233,9 +237,17 @@ Public Class cVERAG_CustomsDeclarations
|
|||||||
" AND z.za_IsFinalDeclaration = 1 " &
|
" AND z.za_IsFinalDeclaration = 1 " &
|
||||||
" AND z.za_DeclarationDate >= @dateFrom " &
|
" AND z.za_DeclarationDate >= @dateFrom " &
|
||||||
" AND z.za_DeclarationDate <= @dateTo " &
|
" AND z.za_DeclarationDate <= @dateTo " &
|
||||||
" AND p.zaParty_EORI = @eori " &
|
" AND p.zaParty_EORI IN (" & eoriIn & ") " &
|
||||||
" AND " & cbamWhere
|
" AND " & cbamWhere
|
||||||
|
|
||||||
|
If indirect Then
|
||||||
|
sqlstr &= " AND (
|
||||||
|
(za_System IN('DHF','DHF_UNISPED') AND za_RepresentationCode=3) OR
|
||||||
|
(za_System IN('TELOTEC') AND za_RepresentationCode=3) OR
|
||||||
|
(za_System IN('DAKOSY') AND za_RepresentationCode=2)
|
||||||
|
)"
|
||||||
|
End If
|
||||||
|
|
||||||
If ImportCountry <> "" Then
|
If ImportCountry <> "" Then
|
||||||
sqlstr &= " AND z.za_CountryImport = @importCountry "
|
sqlstr &= " AND z.za_CountryImport = @importCountry "
|
||||||
End If
|
End If
|
||||||
@@ -244,10 +256,10 @@ Public Class cVERAG_CustomsDeclarations
|
|||||||
sqlstr &= " AND z.za_System = @sys "
|
sqlstr &= " AND z.za_System = @sys "
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Using conn = sql.GetNewOpenConnectionFMZOLL()
|
Using conn = SQL.GetNewOpenConnectionFMZOLL()
|
||||||
Using cmd As New SqlCommand(sqlstr, conn)
|
Using cmd As New SqlCommand(sqlstr, conn)
|
||||||
|
|
||||||
cmd.Parameters.AddWithValue("@eori", EORI)
|
' cmd.Parameters.AddWithValue("@eori", EORI)
|
||||||
cmd.Parameters.AddWithValue("@dateFrom", datFrom)
|
cmd.Parameters.AddWithValue("@dateFrom", datFrom)
|
||||||
cmd.Parameters.AddWithValue("@dateTo", datTo)
|
cmd.Parameters.AddWithValue("@dateTo", datTo)
|
||||||
|
|
||||||
@@ -636,7 +648,7 @@ Public Class cVERAG_CustomsDeclarations_Item
|
|||||||
Dim pi As PropertyInfo =
|
Dim pi As PropertyInfo =
|
||||||
it.GetType().GetProperty(li.Scalarvariable)
|
it.GetType().GetProperty(li.Scalarvariable)
|
||||||
|
|
||||||
If dr.Item(li.Text) Is DBNull.Value Then
|
If dr.Item(li.Text) Is DBNull.Value Then
|
||||||
pi.SetValue(it, Nothing)
|
pi.SetValue(it, Nothing)
|
||||||
Else
|
Else
|
||||||
pi.SetValue(it, dr.Item(li.Text))
|
pi.SetValue(it, dr.Item(li.Text))
|
||||||
|
|||||||
Reference in New Issue
Block a user