div. Auswertungen f. Siener, Sicherheit_3470

This commit is contained in:
2025-10-31 12:15:44 +01:00
parent 76e6691e83
commit 8faaff50a7
6 changed files with 364 additions and 94 deletions

View File

@@ -52,6 +52,13 @@ Partial Class usrCntlAdministration
Me.datKostenstelleBis = New System.Windows.Forms.DateTimePicker()
Me.datKostenstelleVon = New System.Windows.Forms.DateTimePicker()
Me.Button10 = New System.Windows.Forms.Button()
Me.Button12 = New System.Windows.Forms.Button()
Me.Label8 = New System.Windows.Forms.Label()
Me.Button13 = New System.Windows.Forms.Button()
Me.Button14 = New System.Windows.Forms.Button()
Me.Label9 = New System.Windows.Forms.Label()
Me.dt_bis = New System.Windows.Forms.DateTimePicker()
Me.dt_von = New System.Windows.Forms.DateTimePicker()
Me.GroupBox1.SuspendLayout()
Me.GroupBox2.SuspendLayout()
Me.SuspendLayout()
@@ -324,10 +331,12 @@ Partial Class usrCntlAdministration
Me.txtKostenstelleJahr._DateTimeOnly = False
Me.txtKostenstelleJahr._numbersOnly = True
Me.txtKostenstelleJahr._numbersOnlyKommastellen = ""
Me.txtKostenstelleJahr._numbersOnlyTrennzeichen = True
Me.txtKostenstelleJahr._Prozent = False
Me.txtKostenstelleJahr._ShortDateNew = False
Me.txtKostenstelleJahr._ShortDateOnly = False
Me.txtKostenstelleJahr._TimeOnly = False
Me.txtKostenstelleJahr._TimeOnly_Seconds = False
Me.txtKostenstelleJahr._value = ""
Me.txtKostenstelleJahr._Waehrung = False
Me.txtKostenstelleJahr._WaehrungZeichen = True
@@ -405,11 +414,92 @@ Partial Class usrCntlAdministration
Me.Button10.Text = "Kasse Journal-Nr neu berechnen"
Me.Button10.UseVisualStyleBackColor = True
'
'Button12
'
Me.Button12.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button12.ForeColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
Me.Button12.Image = Global.SDL.My.Resources.Resources.Excel_logo
Me.Button12.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button12.Location = New System.Drawing.Point(241, 572)
Me.Button12.Name = "Button12"
Me.Button12.Size = New System.Drawing.Size(211, 24)
Me.Button12.TabIndex = 26
Me.Button12.Text = "Brexit Vorkosten"
Me.Button12.UseVisualStyleBackColor = True
'
'Label8
'
Me.Label8.AutoSize = True
Me.Label8.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label8.Location = New System.Drawing.Point(238, 526)
Me.Label8.Name = "Label8"
Me.Label8.Size = New System.Drawing.Size(91, 13)
Me.Label8.TabIndex = 27
Me.Label8.Text = "Auswertungen:"
'
'Button13
'
Me.Button13.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button13.ForeColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
Me.Button13.Image = Global.SDL.My.Resources.Resources.Excel_logo
Me.Button13.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button13.Location = New System.Drawing.Point(241, 602)
Me.Button13.Name = "Button13"
Me.Button13.Size = New System.Drawing.Size(211, 24)
Me.Button13.TabIndex = 28
Me.Button13.Text = "DL - Ostländer verrechnet"
Me.Button13.UseVisualStyleBackColor = True
'
'Button14
'
Me.Button14.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button14.ForeColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
Me.Button14.Image = Global.SDL.My.Resources.Resources.Excel_logo
Me.Button14.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button14.Location = New System.Drawing.Point(241, 632)
Me.Button14.Name = "Button14"
Me.Button14.Size = New System.Drawing.Size(211, 24)
Me.Button14.TabIndex = 29
Me.Button14.Text = "DL - Ostländer Bar"
Me.Button14.UseVisualStyleBackColor = True
'
'Label9
'
Me.Label9.AutoSize = True
Me.Label9.Location = New System.Drawing.Point(343, 550)
Me.Label9.Name = "Label9"
Me.Label9.Size = New System.Drawing.Size(10, 13)
Me.Label9.TabIndex = 32
Me.Label9.Text = "-"
'
'dt_bis
'
Me.dt_bis.Format = System.Windows.Forms.DateTimePickerFormat.[Short]
Me.dt_bis.Location = New System.Drawing.Point(359, 546)
Me.dt_bis.Name = "dt_bis"
Me.dt_bis.Size = New System.Drawing.Size(82, 20)
Me.dt_bis.TabIndex = 31
'
'dt_von
'
Me.dt_von.Format = System.Windows.Forms.DateTimePickerFormat.[Short]
Me.dt_von.Location = New System.Drawing.Point(256, 546)
Me.dt_von.Name = "dt_von"
Me.dt_von.Size = New System.Drawing.Size(82, 20)
Me.dt_von.TabIndex = 30
'
'usrCntlAdministration
'
Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!)
Me.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font
Me.BackColor = System.Drawing.Color.White
Me.Controls.Add(Me.Label9)
Me.Controls.Add(Me.dt_bis)
Me.Controls.Add(Me.dt_von)
Me.Controls.Add(Me.Button14)
Me.Controls.Add(Me.Button13)
Me.Controls.Add(Me.Label8)
Me.Controls.Add(Me.Button12)
Me.Controls.Add(Me.Button10)
Me.Controls.Add(Me.Label6)
Me.Controls.Add(Me.GroupBox2)
@@ -474,4 +564,11 @@ Partial Class usrCntlAdministration
Friend WithEvents datKostenstelleVon As DateTimePicker
Friend WithEvents Label7 As Label
Friend WithEvents Button10 As Button
Friend WithEvents Button12 As Button
Friend WithEvents Label8 As Label
Friend WithEvents Button13 As Button
Friend WithEvents Button14 As Button
Friend WithEvents Label9 As Label
Friend WithEvents dt_bis As DateTimePicker
Friend WithEvents dt_von As DateTimePicker
End Class

View File

@@ -1,4 +1,8 @@
Public Class usrCntlAdministration
Imports com.sun.tools.internal.xjc.reader.gbind
Imports GrapeCity.ActiveReports.ReportsCore.Tools
Imports GrapeCity.Viewer.Common.Model
Public Class usrCntlAdministration
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
Private Sub btnWord_Click(sender As Object, e As EventArgs) Handles btnWord.Click
@@ -293,4 +297,50 @@
Dim frmKasseJournalNeuBerechnen As New frmKasseJournalNeuBerechnen
frmKasseJournalNeuBerechnen.Show(Me)
End Sub
Private Sub Button12_Click(sender As Object, e As EventArgs) Handles Button12.Click, Button13.Click, Button14.Click
Dim sqlString = ""
Select Case sender.Name
Case "Button12"
sqlString = "SELECT Vorkosten.FilialenNr, Vorkosten.AbfertigungsNr, Vorkosten.Preis, Speditionsbuch.Abfertigungsdatum
FROM Vorkosten INNER JOIN Speditionsbuch ON (Vorkosten.UnterNr = Speditionsbuch.UnterNr) AND (Vorkosten.AbfertigungsNr = Speditionsbuch.AbfertigungsNr) AND (Vorkosten.FilialenNr = Speditionsbuch.FilialenNr)
GROUP BY Vorkosten.FilialenNr, Vorkosten.AbfertigungsNr, Vorkosten.Preis, Speditionsbuch.Abfertigungsdatum
HAVING (Vorkosten.FilialenNr=7001) AND (Speditionsbuch.Abfertigungsdatum) Between '" & dt_von.Value.ToShortDateString & "' And '" & dt_bis.Value.ToShortDateString & "'"
Case "Button13"
Dim FilialenNr = InputBox("Filialen angeben", "Ostländer verrechnet", "4803,4807,4809,4811,4814,4815,4817,4819,4820,4821,4822,4823,4867,4868,4869,5003,5103")
Dim LeistungsNr = InputBox("LeistungsNr angeben", "Ostländer verrechnet", "109,112,260,261,300,301,302,303,304,305,306,307,308,309,310,311,314,315,316,317,319,320,321,322,323,324,325,332,333,334,335,340,341,342,343,344,347,350,351,352,353,354,356,357,358,380,418,422,435,440,441,470,501,502,503,504,505,506,520,521,529,572,610,700,710,750,760")
sqlString = "SELECT Adressen.LandKz, ROUND(Sum(dbo.fktEuro([RechnungsausgangPositionen].[SteuerpflichtigerBetrag]+[RechnungsausgangPositionen].[SteuerfreierBetrag],[Währungscode],'EUR')), 2) AS EURO
FROM (Adressen INNER JOIN Rechnungsausgang ON Adressen.AdressenNr = Rechnungsausgang.RechnungsKundenNr)
INNER JOIN RechnungsausgangPositionen ON Rechnungsausgang.RK_ID = RechnungsausgangPositionen.RK_ID
WHERE RechnungsausgangPositionen.LeistungsNr In (" & LeistungsNr & ")
AND Rechnungsausgang.Abfertigungsdatum Between '" & dt_von.Value.ToShortDateString & "' And '" & dt_bis.Value.ToShortDateString & "'
AND Rechnungsausgang.FilialenNr In (" & FilialenNr & ")
GROUP BY Adressen.LandKz"
Case "Button14"
Dim FilialenNr = InputBox("Filialen für Barzahlungen angeben", "Ostländer Bar", "4803,4805,5303")
sqlString = "SELECT Speditionsbuch.Abfertigungsart, Sum(Speditionsbuch.Barzahlungsbetrag) AS 'Summe von Barzahlungsbetrag'
FROM Speditionsbuch
WHERE Speditionsbuch.FilialenNr In (" & FilialenNr & ") AND Speditionsbuch.Abfertigungsdatum Between '" & dt_von.Value.ToShortDateString & "' And '" & dt_bis.Value.ToShortDateString & "' AND Speditionsbuch.Bar = 1
GROUP BY Speditionsbuch.Abfertigungsart;"
End Select
Dim dt As DataTable = SQL.loadDgvBySql(sqlString, "FMZOLL")
If dt.Rows.Count > 0 Then
cProgramFunctions.genExcelFromDT_NEW(dt)
Else
MsgBox("keine Daten!")
End If
End Sub
End Class

View File

@@ -25,6 +25,7 @@ Partial Public Class rpt_3470
Me.lblCountry = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
Me.lblAmount = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
Me.lblWaehrung = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
Me.lblCreditNodeNo = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
Me.PageFooter = New GrapeCity.ActiveReports.SectionReportModel.PageFooter()
Me.Label28 = New GrapeCity.ActiveReports.SectionReportModel.Label()
Me.Line2 = New GrapeCity.ActiveReports.SectionReportModel.Line()
@@ -38,6 +39,7 @@ Partial Public Class rpt_3470
Me.lblSumGesamt = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
Me.Line3 = New GrapeCity.ActiveReports.SectionReportModel.Line()
Me.GroupHeader1 = New GrapeCity.ActiveReports.SectionReportModel.GroupHeader()
Me.TextBox2 = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
Me.lblKdName_Head = New GrapeCity.ActiveReports.SectionReportModel.Label()
Me.lblKdNr_Head = New GrapeCity.ActiveReports.SectionReportModel.Label()
Me.lblTimePeriod_Head = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
@@ -51,6 +53,7 @@ Partial Public Class rpt_3470
Me.Line18 = New GrapeCity.ActiveReports.SectionReportModel.Line()
Me.Line19 = New GrapeCity.ActiveReports.SectionReportModel.Line()
Me.Line20 = New GrapeCity.ActiveReports.SectionReportModel.Line()
Me.Line4 = New GrapeCity.ActiveReports.SectionReportModel.Line()
Me.GroupFooter1 = New GrapeCity.ActiveReports.SectionReportModel.GroupFooter()
Me.Line1 = New GrapeCity.ActiveReports.SectionReportModel.Line()
Me.lblSumme = New GrapeCity.ActiveReports.SectionReportModel.TextBox()
@@ -65,6 +68,7 @@ Partial Public Class rpt_3470
CType(Me.lblCountry, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblAmount, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblWaehrung, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblCreditNodeNo, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.Label28, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.ReportInfo2, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblDat, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -72,6 +76,7 @@ Partial Public Class rpt_3470
CType(Me.Label3, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblWaehrung_Ges, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblSumGesamt, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.TextBox2, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblKdName_Head, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblKdNr_Head, System.ComponentModel.ISupportInitialize).BeginInit()
CType(Me.lblTimePeriod_Head, System.ComponentModel.ISupportInitialize).BeginInit()
@@ -91,7 +96,7 @@ Partial Public Class rpt_3470
'Detail
'
Me.Detail.BackColor = System.Drawing.Color.White
Me.Detail.Controls.AddRange(New GrapeCity.ActiveReports.SectionReportModel.ARControl() {Me.lblTimeperiod, Me.lblKDNumber, Me.lblKDName, Me.lblCountry, Me.lblAmount, Me.lblWaehrung})
Me.Detail.Controls.AddRange(New GrapeCity.ActiveReports.SectionReportModel.ARControl() {Me.lblTimeperiod, Me.lblKDNumber, Me.lblKDName, Me.lblCountry, Me.lblAmount, Me.lblWaehrung, Me.lblCreditNodeNo})
Me.Detail.Height = 0.200361!
Me.Detail.KeepTogether = True
Me.Detail.Name = "Detail"
@@ -100,14 +105,14 @@ Partial Public Class rpt_3470
'
Me.lblTimeperiod.Height = 0.1795276!
Me.lblTimeperiod.HyperLink = Nothing
Me.lblTimeperiod.Left = 2.73937!
Me.lblTimeperiod.Left = 2.822047!
Me.lblTimeperiod.MultiLine = False
Me.lblTimeperiod.Name = "lblTimeperiod"
Me.lblTimeperiod.Style = "color: Black; font-size: 8pt; font-weight: normal; text-align: center; ddo-char-s" &
"et: 1"
Me.lblTimeperiod.Text = "-"
Me.lblTimeperiod.Top = 0!
Me.lblTimeperiod.Width = 2.802755!
Me.lblTimeperiod.Width = 1.986221!
'
'lblKDNumber
'
@@ -120,35 +125,35 @@ Partial Public Class rpt_3470
"lign: middle; ddo-char-set: 1"
Me.lblKDNumber.Text = "-"
Me.lblKDNumber.Top = 0!
Me.lblKDNumber.Width = 0.81063!
Me.lblKDNumber.Width = 0.8649607!
'
'lblKDName
'
Me.lblKDName.DataField = ""
Me.lblKDName.Height = 0.1795276!
Me.lblKDName.HyperLink = Nothing
Me.lblKDName.Left = 0.8157481!
Me.lblKDName.Left = 0.8700788!
Me.lblKDName.MultiLine = False
Me.lblKDName.Name = "lblKDName"
Me.lblKDName.Style = "color: Black; font-size: 8pt; font-weight: normal; text-align: left; ddo-char-set" &
": 1"
Me.lblKDName.Text = "-"
Me.lblKDName.Top = 0!
Me.lblKDName.Width = 1.923622!
Me.lblKDName.Width = 1.951969!
'
'lblCountry
'
Me.lblCountry.DataField = ""
Me.lblCountry.DistinctField = ""
Me.lblCountry.Height = 0.1795276!
Me.lblCountry.Left = 5.542126!
Me.lblCountry.Left = 4.808268!
Me.lblCountry.MultiLine = False
Me.lblCountry.Name = "lblCountry"
Me.lblCountry.Style = "color: Black; font-size: 8pt; text-align: center; ddo-char-set: 1"
Me.lblCountry.SummaryGroup = ""
Me.lblCountry.Text = Nothing
Me.lblCountry.Top = 0!
Me.lblCountry.Width = 1.505513!
Me.lblCountry.Width = 0.6129925!
'
'lblAmount
'
@@ -162,7 +167,7 @@ Partial Public Class rpt_3470
Me.lblAmount.SummaryGroup = ""
Me.lblAmount.Text = Nothing
Me.lblAmount.Top = 0!
Me.lblAmount.Width = 0.7736225!
Me.lblAmount.Width = 0.8161411!
'
'lblWaehrung
'
@@ -177,6 +182,19 @@ Partial Public Class rpt_3470
Me.lblWaehrung.Top = 0!
Me.lblWaehrung.Width = 0.3401577!
'
'lblCreditNodeNo
'
Me.lblCreditNodeNo.DistinctField = ""
Me.lblCreditNodeNo.Height = 0.1795276!
Me.lblCreditNodeNo.Left = 5.42126!
Me.lblCreditNodeNo.Name = "lblCreditNodeNo"
Me.lblCreditNodeNo.Style = "color: Black; font-size: 8pt; text-align: right; vertical-align: middle; ddo-char" &
"-set: 1"
Me.lblCreditNodeNo.SummaryGroup = ""
Me.lblCreditNodeNo.Text = Nothing
Me.lblCreditNodeNo.Top = 0!
Me.lblCreditNodeNo.Width = 1.678346!
'
'PageFooter
'
Me.PageFooter.Controls.AddRange(New GrapeCity.ActiveReports.SectionReportModel.ARControl() {Me.Label28, Me.Line2, Me.ReportInfo2, Me.lblDat})
@@ -195,14 +213,14 @@ Partial Public Class rpt_3470
'
'Line2
'
Me.Line2.Height = 0!
Me.Line2.Height = 3.72529E-9!
Me.Line2.Left = 0!
Me.Line2.LineWeight = 1.0!
Me.Line2.Name = "Line2"
Me.Line2.Top = 0.03070866!
Me.Line2.Width = 8.267716!
Me.Line2.Width = 8.297638!
Me.Line2.X1 = 0!
Me.Line2.X2 = 8.267716!
Me.Line2.X2 = 8.297638!
Me.Line2.Y1 = 0.03070866!
Me.Line2.Y2 = 0.03070866!
'
@@ -214,7 +232,7 @@ Partial Public Class rpt_3470
Me.ReportInfo2.Name = "ReportInfo2"
Me.ReportInfo2.Style = "font-size: 8pt; text-align: right"
Me.ReportInfo2.Top = 0.08622048!
Me.ReportInfo2.Width = 2.437842!
Me.ReportInfo2.Width = 2.467716!
'
'lblDat
'
@@ -286,7 +304,7 @@ Partial Public Class rpt_3470
Me.lblSumGesamt.SummaryGroup = ""
Me.lblSumGesamt.Text = "10.000.000"
Me.lblSumGesamt.Top = 0.08070867!
Me.lblSumGesamt.Width = 1.05!
Me.lblSumGesamt.Width = 1.092519!
'
'Line3
'
@@ -295,24 +313,37 @@ Partial Public Class rpt_3470
Me.Line3.LineWeight = 1.0!
Me.Line3.Name = "Line3"
Me.Line3.Top = 0.08070867!
Me.Line3.Width = 2.725592!
Me.Line3.Width = 2.76811!
Me.Line3.X1 = 5.529528!
Me.Line3.X2 = 8.255119!
Me.Line3.X2 = 8.297638!
Me.Line3.Y1 = 0.08070869!
Me.Line3.Y2 = 0.08070867!
'
'GroupHeader1
'
Me.GroupHeader1.Controls.AddRange(New GrapeCity.ActiveReports.SectionReportModel.ARControl() {Me.lblKdName_Head, Me.lblKdNr_Head, Me.lblTimePeriod_Head, Me.lblCountry_Head, Me.lblAmount_Head, Me.Line12, Me.Line14, Me.Line15, Me.Line16, Me.Line17, Me.Line18, Me.Line19, Me.Line20})
Me.GroupHeader1.Controls.AddRange(New GrapeCity.ActiveReports.SectionReportModel.ARControl() {Me.TextBox2, Me.lblKdName_Head, Me.lblKdNr_Head, Me.lblTimePeriod_Head, Me.lblCountry_Head, Me.lblAmount_Head, Me.Line12, Me.Line14, Me.Line15, Me.Line16, Me.Line17, Me.Line18, Me.Line19, Me.Line20, Me.Line4})
Me.GroupHeader1.Height = 0.227592!
Me.GroupHeader1.KeepTogether = True
Me.GroupHeader1.Name = "GroupHeader1"
'
'TextBox2
'
Me.TextBox2.DistinctField = ""
Me.TextBox2.Height = 0.1795276!
Me.TextBox2.Left = 5.42126!
Me.TextBox2.Name = "TextBox2"
Me.TextBox2.Style = "color: Black; font-size: 8pt; font-weight: bold; text-align: center; ddo-char-set" &
": 1"
Me.TextBox2.SummaryGroup = ""
Me.TextBox2.Text = "Credit Node No."
Me.TextBox2.Top = 0.003937008!
Me.TextBox2.Width = 1.678346!
'
'lblKdName_Head
'
Me.lblKdName_Head.Height = 0.1795276!
Me.lblKdName_Head.HyperLink = Nothing
Me.lblKdName_Head.Left = 0.7866142!
Me.lblKdName_Head.Left = 0.8700788!
Me.lblKdName_Head.Name = "lblKdName_Head"
Me.lblKdName_Head.Style = "font-size: 9pt; font-weight: bold; text-align: left; ddo-char-set: 1"
Me.lblKdName_Head.Text = "Name"
@@ -326,37 +357,37 @@ Partial Public Class rpt_3470
Me.lblKdNr_Head.Left = 0.01023622!
Me.lblKdNr_Head.Name = "lblKdNr_Head"
Me.lblKdNr_Head.Style = "font-size: 9pt; font-weight: bold; text-align: left; ddo-char-set: 1"
Me.lblKdNr_Head.Text = "Number"
Me.lblKdNr_Head.Text = "Customer No."
Me.lblKdNr_Head.Top = 0!
Me.lblKdNr_Head.Width = 0.7429135!
Me.lblKdNr_Head.Width = 0.8598426!
'
'lblTimePeriod_Head
'
Me.lblTimePeriod_Head.DataField = ""
Me.lblTimePeriod_Head.DistinctField = ""
Me.lblTimePeriod_Head.Height = 0.1795276!
Me.lblTimePeriod_Head.Left = 2.73937!
Me.lblTimePeriod_Head.Left = 2.822835!
Me.lblTimePeriod_Head.Name = "lblTimePeriod_Head"
Me.lblTimePeriod_Head.Style = "color: Black; font-size: 8pt; font-weight: bold; text-align: center; ddo-char-set" &
": 1"
Me.lblTimePeriod_Head.SummaryGroup = ""
Me.lblTimePeriod_Head.Text = "Time Period"
Me.lblTimePeriod_Head.Top = 0!
Me.lblTimePeriod_Head.Width = 2.802756!
Me.lblTimePeriod_Head.Width = 1.985433!
'
'lblCountry_Head
'
Me.lblCountry_Head.DataField = ""
Me.lblCountry_Head.DistinctField = ""
Me.lblCountry_Head.Height = 0.1795276!
Me.lblCountry_Head.Left = 5.542126!
Me.lblCountry_Head.Left = 4.808268!
Me.lblCountry_Head.Name = "lblCountry_Head"
Me.lblCountry_Head.Style = "color: Black; font-size: 8pt; font-weight: bold; text-align: center; ddo-char-set" &
": 1"
Me.lblCountry_Head.SummaryGroup = ""
Me.lblCountry_Head.Text = "Country"
Me.lblCountry_Head.Top = 0!
Me.lblCountry_Head.Width = 1.519685!
Me.lblCountry_Head.Top = 0.003937008!
Me.lblCountry_Head.Width = 0.612992!
'
'lblAmount_Head
'
@@ -414,28 +445,28 @@ Partial Public Class rpt_3470
'Line16
'
Me.Line16.Height = 0.1795276!
Me.Line16.Left = 0.7866142!
Me.Line16.Left = 0.8700787!
Me.Line16.LineWeight = 1.0!
Me.Line16.Name = "Line16"
Me.Line16.Top = 0!
Me.Line16.Width = 0.000787437!
Me.Line16.X1 = 0.7874016!
Me.Line16.X2 = 0.7866142!
Me.Line16.X1 = 0.8708662!
Me.Line16.X2 = 0.8700787!
Me.Line16.Y1 = 0.1795276!
Me.Line16.Y2 = 0!
'
'Line17
'
Me.Line17.Height = 0.1795275!
Me.Line17.Left = 5.542126!
Me.Line17.Left = 4.808268!
Me.Line17.LineWeight = 1.0!
Me.Line17.Name = "Line17"
Me.Line17.Top = 0.0000001192093!
Me.Line17.Top = 0.00000008940698!
Me.Line17.Width = 0!
Me.Line17.X1 = 5.542126!
Me.Line17.X2 = 5.542126!
Me.Line17.X1 = 4.808268!
Me.Line17.X2 = 4.808268!
Me.Line17.Y1 = 0.1795276!
Me.Line17.Y2 = 0.0000001192093!
Me.Line17.Y2 = 0.00000008940698!
'
'Line18
'
@@ -466,16 +497,29 @@ Partial Public Class rpt_3470
'Line20
'
Me.Line20.Height = 0.1795276!
Me.Line20.Left = 2.738582!
Me.Line20.Left = 2.822047!
Me.Line20.LineWeight = 1.0!
Me.Line20.Name = "Line20"
Me.Line20.Top = 0!
Me.Line20.Width = 0.0007882118!
Me.Line20.X1 = 2.73937!
Me.Line20.X2 = 2.738582!
Me.Line20.X1 = 2.822835!
Me.Line20.X2 = 2.822047!
Me.Line20.Y1 = 0.1795276!
Me.Line20.Y2 = 0!
'
'Line4
'
Me.Line4.Height = 0.1795276!
Me.Line4.Left = 5.42126!
Me.Line4.LineWeight = 1.0!
Me.Line4.Name = "Line4"
Me.Line4.Top = 0!
Me.Line4.Width = 0!
Me.Line4.X1 = 5.42126!
Me.Line4.X2 = 5.42126!
Me.Line4.Y1 = 0.1795276!
Me.Line4.Y2 = 0!
'
'GroupFooter1
'
Me.GroupFooter1.Controls.AddRange(New GrapeCity.ActiveReports.SectionReportModel.ARControl() {Me.Line1, Me.lblSumme, Me.lblWahrung, Me.lblGroup1})
@@ -489,9 +533,9 @@ Partial Public Class rpt_3470
Me.Line1.LineWeight = 1.0!
Me.Line1.Name = "Line1"
Me.Line1.Top = 0.09251969!
Me.Line1.Width = 2.72559!
Me.Line1.Width = 2.755512!
Me.Line1.X1 = 5.542126!
Me.Line1.X2 = 8.267716!
Me.Line1.X2 = 8.297638!
Me.Line1.Y1 = 0.09251969!
Me.Line1.Y2 = 0.09251969!
'
@@ -507,7 +551,7 @@ Partial Public Class rpt_3470
Me.lblSumme.SummaryGroup = ""
Me.lblSumme.Text = "10.000.000"
Me.lblSumme.Top = 0.1122047!
Me.lblSumme.Width = 1.05!
Me.lblSumme.Width = 1.079921!
'
'lblWahrung
'
@@ -596,6 +640,7 @@ Partial Public Class rpt_3470
CType(Me.lblCountry, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblAmount, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblWaehrung, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblCreditNodeNo, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.Label28, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.ReportInfo2, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblDat, System.ComponentModel.ISupportInitialize).EndInit()
@@ -603,6 +648,7 @@ Partial Public Class rpt_3470
CType(Me.Label3, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblWaehrung_Ges, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblSumGesamt, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.TextBox2, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblKdName_Head, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblKdNr_Head, System.ComponentModel.ISupportInitialize).EndInit()
CType(Me.lblTimePeriod_Head, System.ComponentModel.ISupportInitialize).EndInit()
@@ -655,4 +701,7 @@ Partial Public Class rpt_3470
Private WithEvents Line3 As GrapeCity.ActiveReports.SectionReportModel.Line
Public WithEvents lblWaehrung_Ges As GrapeCity.ActiveReports.SectionReportModel.TextBox
Public WithEvents lblGroup1 As GrapeCity.ActiveReports.SectionReportModel.TextBox
Public WithEvents lblCreditNodeNo As GrapeCity.ActiveReports.SectionReportModel.TextBox
Private WithEvents TextBox2 As GrapeCity.ActiveReports.SectionReportModel.TextBox
Private WithEvents Line4 As GrapeCity.ActiveReports.SectionReportModel.Line
End Class

View File

@@ -1,4 +1,5 @@
Imports System.ComponentModel
Imports com.sun.org.apache.bcel.internal.generic
Imports com.sun.xml.internal.rngom
Imports DocumentFormat.OpenXml.Drawing
Imports Microsoft.Office.Interop
@@ -1388,20 +1389,28 @@ Public Class usrCntlUSTV
If item IsNot Nothing Then
Dim sql_Query As String = ""
Dim KdNr_Auswahl As Integer = -1
If kdNr > 0 Then
',[UStVAn_Währungscode] as Währung
sql_Query = "SELECT [UStVAn_KuNr] as Kunde,[UStVAn_Name] as Name,UStVAn_LandKz, [UStVAn_ReDatVon] as von, [UStVAn_ReDatBis] as bis,LandKz as Land, [UStVAn_3470] as Betrag FROM [tblUStVAntrag] inner join [Länderverzeichnis für die Außenhandelsstatistik] on UStVAn_LandNr=Landnr
where isnull([UStVAn_3470], 0) <> 0 and [UStVAn_KuNr] = " & kdNr & "
order by UStVAn_KuNr,UStVAn_Name,datepart(year,[UStVAn_ReDatVon]) asc,LandKz,[UStVAn_ReDatVon] asc"
Else
sql_Query = "SELECT [UStVAn_KuNr] as Kunde,[UStVAn_Name] as Name,UStVAn_LandKz, [UStVAn_ReDatVon] as von, [UStVAn_ReDatBis] as bis,LandKz as Land, [UStVAn_3470] as Betrag FROM [tblUStVAntrag] inner join [Länderverzeichnis für die Außenhandelsstatistik] on UStVAn_LandNr=Landnr
where isnull([UStVAn_3470], 0) <> 0
order by UStVAn_KuNr,UStVAn_Name,datepart(year,[UStVAn_ReDatVon]) asc,LandKz,[UStVAn_ReDatVon] asc"
KdNr_Auswahl = kdNr
ElseIf KdSearchBox1 IsNot Nothing AndAlso KdSearchBox1.KdNr > 0 Then
KdNr_Auswahl = KdSearchBox1.KdNr
End If
Dim sql_Query As String = "SELECT [UStVAn_KuNr] AS 'Customer No.', [UStVAn_Name] As Name, UStVAn_LandKz as 'Customer Country', [UStVAn_ReDatVon] As 'from', [UStVAn_ReDatBis] As 'to', LandKz As Country, [UStVAn_3470] As Amount,
STUFF((
SELECT ', ' + CAST(e.GutschriftsNr AS VARCHAR(50))
From tblUStVErstattung e
Where e.UStVAn_ID = a.UStVAn_ID
FOR XML PATH(''), TYPE
).value('.', 'NVARCHAR(MAX)'), 1, 2, '') AS 'Credit Note No.'
FROM [tblUStVAntrag] a
INNER JOIN [Länderverzeichnis für die Außenhandelsstatistik] l ON a.UStVAn_LandNr = l.Landnr
WHERE ISNULL([UStVAn_3470], 0) <> 0 " & IIf(KdNr_Auswahl > 0, "AND [UStVAn_KuNr] = " & KdNr_Auswahl & "", "") & "
ORDER BY UStVAn_KuNr,UStVAn_Name, DATEPART(YEAR, [UStVAn_ReDatVon]) ASC,LandKz,[UStVAn_ReDatVon] ASC"
Dim dtVorschau_3470 As DataTable = SQL.loadDgvBySql(sql_Query, "FMZOLL")
If item.Name = "excel" Then
@@ -1418,21 +1427,21 @@ Public Class usrCntlUSTV
Dim Mail As Microsoft.Office.Interop.Outlook.MailItem
Mail = outl.CreateItem(0)
Dim groupField = ""
If kdNr > 0 Then
groupField = "UStVAn_LandKz"
Dim ADR As New cAdressen(kdNr)
If KdNr_Auswahl > 0 Then
groupField = "Customer Country"
Dim ADR As New cAdressen(KdNr_Auswahl)
Mail.To = ADR.E_Mail
If Mail.To <> "" AndAlso ADR.E_Mail2 <> "" Then Mail.To &= ";" & ADR.E_Mail2
Else
groupField = "Kunde"
groupField = "Customer No."
End If
Dim filePathExcel = cProgramFunctions.genExcelFromDT_NEW(dtVorschau_3470, {"F1:F" & (dtVorschau_3470.Rows.Count + 1)}, False,,,, True,,,, False)
Dim FilePath_PDF = create4870Report(dtVorschau_3470, groupField)
Dim FilePath_PDF = create3470Report(dtVorschau_3470, groupField)
Mail.Attachments.Add(filePathExcel, Microsoft.Office.Interop.Outlook.OlAttachmentType.olByValue,, "AccountNo_4870.xslx")
Mail.Attachments.Add(FilePath_PDF, Microsoft.Office.Interop.Outlook.OlAttachmentType.olByValue,, "AccountNo_4870.pdf")
Mail.Attachments.Add(filePathExcel, Microsoft.Office.Interop.Outlook.OlAttachmentType.olByValue,, "AccountNo_3470.xslx")
Mail.Attachments.Add(FilePath_PDF, Microsoft.Office.Interop.Outlook.OlAttachmentType.olByValue,, "AccountNo_3470.pdf")
Mail.Display()
Catch ex As Exception
@@ -1442,15 +1451,15 @@ Public Class usrCntlUSTV
ElseIf item.Name = "pdf" Then
Dim groupField = ""
If kdNr > 0 Then
groupField = "UStVAn_LandKz"
If KdNr_Auswahl > 0 Then
groupField = "Customer Country"
Else
groupField = "Kunde"
groupField = "Customer No."
End If
create4870Report(dtVorschau_3470, groupField, True)
create3470Report(dtVorschau_3470, groupField, True)
End If
@@ -1462,7 +1471,7 @@ Public Class usrCntlUSTV
End Sub
Private Function create4870Report(dt As DataTable, GroupField As String, Optional open As Boolean = False) As String
Private Function create3470Report(dt As DataTable, GroupField As String, Optional open As Boolean = False) As String
Dim rpt As New rpt_3470
@@ -1481,8 +1490,8 @@ Public Class usrCntlUSTV
AddHandler rpt.ReportHeader1.Format, Sub()
If GroupField = "UStVAn_LandKz" Then
rpt.Label3.Text &= " - " & rpt.Fields.Item("UStVAn_LandKz").Value()
If GroupField = "Customer Country" Then
rpt.Label3.Text &= " - " & rpt.Fields.Item("Customer Country").Value()
End If
End Sub
@@ -1490,22 +1499,22 @@ Public Class usrCntlUSTV
AddHandler rpt.Detail.Format, Sub()
rpt.lblKDName.Text = rpt.Fields.Item("Name").Value()
rpt.lblKDNumber.Text = rpt.Fields.Item("Kunde").Value()
rpt.lblCountry.Text = rpt.Fields.Item("Land").Value()
rpt.lblAmount.Text = CDbl(rpt.Fields.Item("Betrag").Value()).ToString("N2") & ""
'rpt.lblWaehrung.Text = rpt.Fields.Item("Währung").Value()
rpt.lblTimeperiod.Text = CDate((rpt.Fields.Item("von").Value())).ToShortDateString & " - " & CDate((rpt.Fields.Item("bis").Value())).ToShortDateString
rpt.lblKDNumber.Text = rpt.Fields.Item("Customer No.").Value()
rpt.lblCountry.Text = rpt.Fields.Item("Country").Value()
rpt.lblAmount.Text = CDbl(rpt.Fields.Item("Amount").Value()).ToString("N2") & ""
rpt.lblCreditNodeNo.Text = IIf(Not IsDBNull(rpt.Fields.Item("Credit Note No.").Value()), rpt.Fields.Item("Credit Note No.").Value(), "-")
rpt.lblTimeperiod.Text = CDate((rpt.Fields.Item("from").Value())).ToShortDateString & " - " & CDate((rpt.Fields.Item("to").Value())).ToShortDateString
sum += CDbl(rpt.Fields.Item("Betrag").Value()).ToString("N2")
sumGroup += CDbl(rpt.Fields.Item("Betrag").Value()).ToString("N2")
sum += CDbl(rpt.Fields.Item("Amount").Value()).ToString("N2")
sumGroup += CDbl(rpt.Fields.Item("Amount").Value()).ToString("N2")
End Sub
AddHandler rpt.GroupFooter1.Format, Sub()
If GroupField = "UStVAn_LandKz" Then
If GroupField = "Customer Country" Then
'rpt.lblGroup1.Text = rpt.Fields.Item("UStVAn_LandKz").Value()
rpt.lblWahrung.Text = rpt.Fields.Item("UStVAn_LandKz").Value()
rpt.lblWahrung.Text = rpt.Fields.Item("Customer Country").Value()
End If
rpt.lblSumme.Text = sumGroup.ToString("N2") & ""

View File

@@ -97,6 +97,7 @@ Partial Class frmKassenbuchSuche
Me.EintragLöschenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem()
Me.pnlOpt = New System.Windows.Forms.Panel()
Me.pnl = New System.Windows.Forms.Panel()
Me.Button3 = New System.Windows.Forms.Button()
Me.MyComboBox2 = New VERAG_PROG_ALLGEMEIN.MyComboBox()
Me.Label21 = New System.Windows.Forms.Label()
Me.MyComboBox1 = New VERAG_PROG_ALLGEMEIN.MyComboBox()
@@ -113,7 +114,8 @@ Partial Class frmKassenbuchSuche
Me.Label22 = New System.Windows.Forms.Label()
Me.Label4 = New System.Windows.Forms.Label()
Me.pnlTop = New System.Windows.Forms.Panel()
Me.Button3 = New System.Windows.Forms.Button()
Me.Label12 = New System.Windows.Forms.Label()
Me.cbxZahlungsmittel = New VERAG_PROG_ALLGEMEIN.MyComboBox()
CType(Me.SplitContainer, System.ComponentModel.ISupportInitialize).BeginInit()
Me.SplitContainer.Panel1.SuspendLayout()
Me.SplitContainer.Panel2.SuspendLayout()
@@ -217,6 +219,8 @@ Partial Class frmKassenbuchSuche
'
'SplitContainer1.Panel2
'
Me.SplitContainer1.Panel2.Controls.Add(Me.Label12)
Me.SplitContainer1.Panel2.Controls.Add(Me.cbxZahlungsmittel)
Me.SplitContainer1.Panel2.Controls.Add(Me.Label6)
Me.SplitContainer1.Panel2.Controls.Add(Me.btnDGVBelege)
Me.SplitContainer1.Panel2.Controls.Add(Me.btnDGVKassenbuch)
@@ -376,10 +380,12 @@ Partial Class frmKassenbuchSuche
Me.MyTextBox1._DateTimeOnly = False
Me.MyTextBox1._numbersOnly = False
Me.MyTextBox1._numbersOnlyKommastellen = ""
Me.MyTextBox1._numbersOnlyTrennzeichen = True
Me.MyTextBox1._Prozent = False
Me.MyTextBox1._ShortDateNew = False
Me.MyTextBox1._ShortDateOnly = False
Me.MyTextBox1._TimeOnly = False
Me.MyTextBox1._TimeOnly_Seconds = False
Me.MyTextBox1._value = Nothing
Me.MyTextBox1._Waehrung = False
Me.MyTextBox1._WaehrungZeichen = True
@@ -399,10 +405,12 @@ Partial Class frmKassenbuchSuche
Me.MyTextBox2._DateTimeOnly = False
Me.MyTextBox2._numbersOnly = False
Me.MyTextBox2._numbersOnlyKommastellen = ""
Me.MyTextBox2._numbersOnlyTrennzeichen = True
Me.MyTextBox2._Prozent = False
Me.MyTextBox2._ShortDateNew = False
Me.MyTextBox2._ShortDateOnly = False
Me.MyTextBox2._TimeOnly = False
Me.MyTextBox2._TimeOnly_Seconds = False
Me.MyTextBox2._value = Nothing
Me.MyTextBox2._Waehrung = False
Me.MyTextBox2._WaehrungZeichen = True
@@ -464,7 +472,7 @@ Partial Class frmKassenbuchSuche
'
Me.btnSuche.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.btnSuche.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.btnSuche.Image = Global.SDL.My.Resources.search
Me.btnSuche.Image = Global.SDL.My.Resources.Resources.search
Me.btnSuche.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.btnSuche.Location = New System.Drawing.Point(1043, 6)
Me.btnSuche.Name = "btnSuche"
@@ -478,10 +486,12 @@ Partial Class frmKassenbuchSuche
Me.txtAbfertDat._DateTimeOnly = False
Me.txtAbfertDat._numbersOnly = False
Me.txtAbfertDat._numbersOnlyKommastellen = ""
Me.txtAbfertDat._numbersOnlyTrennzeichen = True
Me.txtAbfertDat._Prozent = False
Me.txtAbfertDat._ShortDateNew = False
Me.txtAbfertDat._ShortDateOnly = True
Me.txtAbfertDat._TimeOnly = False
Me.txtAbfertDat._TimeOnly_Seconds = False
Me.txtAbfertDat._value = ""
Me.txtAbfertDat._Waehrung = False
Me.txtAbfertDat._WaehrungZeichen = True
@@ -600,7 +610,7 @@ Partial Class frmKassenbuchSuche
Me.Button4.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button4.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.0!, System.Drawing.FontStyle.Bold)
Me.Button4.ForeColor = System.Drawing.Color.White
Me.Button4.Image = Global.SDL.My.Resources.pfeil_unten
Me.Button4.Image = Global.SDL.My.Resources.Resources.pfeil_unten
Me.Button4.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button4.Location = New System.Drawing.Point(1043, 57)
Me.Button4.Margin = New System.Windows.Forms.Padding(0)
@@ -616,10 +626,12 @@ Partial Class frmKassenbuchSuche
Me.txtAbfertDatBis._DateTimeOnly = False
Me.txtAbfertDatBis._numbersOnly = False
Me.txtAbfertDatBis._numbersOnlyKommastellen = ""
Me.txtAbfertDatBis._numbersOnlyTrennzeichen = True
Me.txtAbfertDatBis._Prozent = False
Me.txtAbfertDatBis._ShortDateNew = False
Me.txtAbfertDatBis._ShortDateOnly = True
Me.txtAbfertDatBis._TimeOnly = False
Me.txtAbfertDatBis._TimeOnly_Seconds = False
Me.txtAbfertDatBis._value = ""
Me.txtAbfertDatBis._Waehrung = False
Me.txtAbfertDatBis._WaehrungZeichen = True
@@ -711,10 +723,12 @@ Partial Class frmKassenbuchSuche
Me.txtUnterNr._DateTimeOnly = False
Me.txtUnterNr._numbersOnly = False
Me.txtUnterNr._numbersOnlyKommastellen = ""
Me.txtUnterNr._numbersOnlyTrennzeichen = True
Me.txtUnterNr._Prozent = False
Me.txtUnterNr._ShortDateNew = False
Me.txtUnterNr._ShortDateOnly = False
Me.txtUnterNr._TimeOnly = False
Me.txtUnterNr._TimeOnly_Seconds = False
Me.txtUnterNr._value = Nothing
Me.txtUnterNr._Waehrung = False
Me.txtUnterNr._WaehrungZeichen = True
@@ -743,10 +757,12 @@ Partial Class frmKassenbuchSuche
Me.txtAbfertigungsnummerBis._DateTimeOnly = False
Me.txtAbfertigungsnummerBis._numbersOnly = False
Me.txtAbfertigungsnummerBis._numbersOnlyKommastellen = ""
Me.txtAbfertigungsnummerBis._numbersOnlyTrennzeichen = True
Me.txtAbfertigungsnummerBis._Prozent = False
Me.txtAbfertigungsnummerBis._ShortDateNew = False
Me.txtAbfertigungsnummerBis._ShortDateOnly = False
Me.txtAbfertigungsnummerBis._TimeOnly = False
Me.txtAbfertigungsnummerBis._TimeOnly_Seconds = False
Me.txtAbfertigungsnummerBis._value = Nothing
Me.txtAbfertigungsnummerBis._Waehrung = False
Me.txtAbfertigungsnummerBis._WaehrungZeichen = True
@@ -766,10 +782,12 @@ Partial Class frmKassenbuchSuche
Me.txtAbfertigungsnummer._DateTimeOnly = False
Me.txtAbfertigungsnummer._numbersOnly = False
Me.txtAbfertigungsnummer._numbersOnlyKommastellen = ""
Me.txtAbfertigungsnummer._numbersOnlyTrennzeichen = True
Me.txtAbfertigungsnummer._Prozent = False
Me.txtAbfertigungsnummer._ShortDateNew = False
Me.txtAbfertigungsnummer._ShortDateOnly = False
Me.txtAbfertigungsnummer._TimeOnly = False
Me.txtAbfertigungsnummer._TimeOnly_Seconds = False
Me.txtAbfertigungsnummer._value = Nothing
Me.txtAbfertigungsnummer._Waehrung = False
Me.txtAbfertigungsnummer._WaehrungZeichen = True
@@ -834,6 +852,7 @@ Partial Class frmKassenbuchSuche
'
'KdFrachtfuehrer
'
Me.KdFrachtfuehrer._AlleFirmenCLUSTER = False
Me.KdFrachtfuehrer._AllowSetValue = True
Me.KdFrachtfuehrer._autoSizeGross = False
Me.KdFrachtfuehrer._display_Name1 = False
@@ -842,6 +861,8 @@ Partial Class frmKassenbuchSuche
Me.KdFrachtfuehrer._displayWoelflKd = False
Me.KdFrachtfuehrer._hideIfListEmpty = True
Me.KdFrachtfuehrer._loadKdData = False
Me.KdFrachtfuehrer._searchName1 = True
Me.KdFrachtfuehrer._UseFIRMA = ""
Me.KdFrachtfuehrer._ValueKdAndName = True
Me.KdFrachtfuehrer.dgvpos = "LEFT"
Me.KdFrachtfuehrer.KdName = ""
@@ -854,6 +875,7 @@ Partial Class frmKassenbuchSuche
Me.KdFrachtfuehrer.searchActive = True
Me.KdFrachtfuehrer.Size = New System.Drawing.Size(261, 20)
Me.KdFrachtfuehrer.TabIndex = 46
Me.KdFrachtfuehrer.TIMER_SEARCH = True
Me.KdFrachtfuehrer.usrcntl = Nothing
'
'Label37
@@ -871,10 +893,12 @@ Partial Class frmKassenbuchSuche
Me.KdFrachtfuehrerKdnr._DateTimeOnly = False
Me.KdFrachtfuehrerKdnr._numbersOnly = False
Me.KdFrachtfuehrerKdnr._numbersOnlyKommastellen = ""
Me.KdFrachtfuehrerKdnr._numbersOnlyTrennzeichen = True
Me.KdFrachtfuehrerKdnr._Prozent = False
Me.KdFrachtfuehrerKdnr._ShortDateNew = False
Me.KdFrachtfuehrerKdnr._ShortDateOnly = False
Me.KdFrachtfuehrerKdnr._TimeOnly = False
Me.KdFrachtfuehrerKdnr._TimeOnly_Seconds = False
Me.KdFrachtfuehrerKdnr._value = Nothing
Me.KdFrachtfuehrerKdnr._Waehrung = False
Me.KdFrachtfuehrerKdnr._WaehrungZeichen = True
@@ -1017,10 +1041,12 @@ Partial Class frmKassenbuchSuche
Me.txtLKWKennzeichen._DateTimeOnly = False
Me.txtLKWKennzeichen._numbersOnly = False
Me.txtLKWKennzeichen._numbersOnlyKommastellen = ""
Me.txtLKWKennzeichen._numbersOnlyTrennzeichen = True
Me.txtLKWKennzeichen._Prozent = False
Me.txtLKWKennzeichen._ShortDateNew = False
Me.txtLKWKennzeichen._ShortDateOnly = False
Me.txtLKWKennzeichen._TimeOnly = False
Me.txtLKWKennzeichen._TimeOnly_Seconds = False
Me.txtLKWKennzeichen._value = Nothing
Me.txtLKWKennzeichen._Waehrung = False
Me.txtLKWKennzeichen._WaehrungZeichen = True
@@ -1068,6 +1094,7 @@ Partial Class frmKassenbuchSuche
'
'kdtxtAuftraggeber
'
Me.kdtxtAuftraggeber._AlleFirmenCLUSTER = False
Me.kdtxtAuftraggeber._AllowSetValue = True
Me.kdtxtAuftraggeber._autoSizeGross = False
Me.kdtxtAuftraggeber._display_Name1 = False
@@ -1076,6 +1103,8 @@ Partial Class frmKassenbuchSuche
Me.kdtxtAuftraggeber._displayWoelflKd = False
Me.kdtxtAuftraggeber._hideIfListEmpty = True
Me.kdtxtAuftraggeber._loadKdData = False
Me.kdtxtAuftraggeber._searchName1 = True
Me.kdtxtAuftraggeber._UseFIRMA = ""
Me.kdtxtAuftraggeber._ValueKdAndName = True
Me.kdtxtAuftraggeber.dgvpos = "LEFT"
Me.kdtxtAuftraggeber.KdName = ""
@@ -1088,6 +1117,7 @@ Partial Class frmKassenbuchSuche
Me.kdtxtAuftraggeber.searchActive = True
Me.kdtxtAuftraggeber.Size = New System.Drawing.Size(261, 20)
Me.kdtxtAuftraggeber.TabIndex = 17
Me.kdtxtAuftraggeber.TIMER_SEARCH = True
Me.kdtxtAuftraggeber.usrcntl = Nothing
'
'txtAuftraggeberKdnr
@@ -1095,10 +1125,12 @@ Partial Class frmKassenbuchSuche
Me.txtAuftraggeberKdnr._DateTimeOnly = False
Me.txtAuftraggeberKdnr._numbersOnly = False
Me.txtAuftraggeberKdnr._numbersOnlyKommastellen = ""
Me.txtAuftraggeberKdnr._numbersOnlyTrennzeichen = True
Me.txtAuftraggeberKdnr._Prozent = False
Me.txtAuftraggeberKdnr._ShortDateNew = False
Me.txtAuftraggeberKdnr._ShortDateOnly = False
Me.txtAuftraggeberKdnr._TimeOnly = False
Me.txtAuftraggeberKdnr._TimeOnly_Seconds = False
Me.txtAuftraggeberKdnr._value = Nothing
Me.txtAuftraggeberKdnr._Waehrung = False
Me.txtAuftraggeberKdnr._WaehrungZeichen = True
@@ -1119,10 +1151,12 @@ Partial Class frmKassenbuchSuche
Me.txtBelegId._DateTimeOnly = False
Me.txtBelegId._numbersOnly = False
Me.txtBelegId._numbersOnlyKommastellen = ""
Me.txtBelegId._numbersOnlyTrennzeichen = True
Me.txtBelegId._Prozent = False
Me.txtBelegId._ShortDateNew = False
Me.txtBelegId._ShortDateOnly = False
Me.txtBelegId._TimeOnly = False
Me.txtBelegId._TimeOnly_Seconds = False
Me.txtBelegId._value = Nothing
Me.txtBelegId._Waehrung = False
Me.txtBelegId._WaehrungZeichen = True
@@ -1211,6 +1245,21 @@ Partial Class frmKassenbuchSuche
Me.pnl.Size = New System.Drawing.Size(1047, 78)
Me.pnl.TabIndex = 5
'
'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.Image = Global.SDL.My.Resources.Resources.statistik_small
Me.Button3.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button3.Location = New System.Drawing.Point(283, 32)
Me.Button3.Margin = New System.Windows.Forms.Padding(0)
Me.Button3.Name = "Button3"
Me.Button3.Size = New System.Drawing.Size(156, 39)
Me.Button3.TabIndex = 47
Me.Button3.Text = "SollHaben Auswertung"
Me.Button3.TextAlign = System.Drawing.ContentAlignment.MiddleRight
Me.Button3.UseVisualStyleBackColor = True
'
'MyComboBox2
'
Me.MyComboBox2._allowedValuesFreiText = Nothing
@@ -1251,7 +1300,7 @@ Partial Class frmKassenbuchSuche
'
Me.Button1.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.Button1.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button1.Image = Global.SDL.My.Resources.statistik_small
Me.Button1.Image = Global.SDL.My.Resources.Resources.statistik_small
Me.Button1.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button1.Location = New System.Drawing.Point(832, 10)
Me.Button1.Margin = New System.Windows.Forms.Padding(0)
@@ -1316,7 +1365,7 @@ Partial Class frmKassenbuchSuche
'
Me.Button8.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.Button8.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.Button8.Image = Global.SDL.My.Resources.statistik_small
Me.Button8.Image = Global.SDL.My.Resources.Resources.statistik_small
Me.Button8.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button8.Location = New System.Drawing.Point(16, 32)
Me.Button8.Margin = New System.Windows.Forms.Padding(0)
@@ -1340,7 +1389,7 @@ Partial Class frmKassenbuchSuche
'btnExcel
'
Me.btnExcel.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.btnExcel.BackgroundImage = Global.SDL.My.Resources.Excel_logo
Me.btnExcel.BackgroundImage = Global.SDL.My.Resources.Resources.Excel_logo
Me.btnExcel.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Center
Me.btnExcel.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.btnExcel.Location = New System.Drawing.Point(1117, 37)
@@ -1352,7 +1401,7 @@ Partial Class frmKassenbuchSuche
'FlatButton7
'
Me.FlatButton7.Anchor = CType((System.Windows.Forms.AnchorStyles.Bottom Or System.Windows.Forms.AnchorStyles.Left), System.Windows.Forms.AnchorStyles)
Me.FlatButton7.BackgroundImage = Global.SDL.My.Resources.refresh
Me.FlatButton7.BackgroundImage = Global.SDL.My.Resources.Resources.refresh
Me.FlatButton7.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
Me.FlatButton7.FlatStyle = System.Windows.Forms.FlatStyle.Flat
Me.FlatButton7.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
@@ -1405,20 +1454,28 @@ Partial Class frmKassenbuchSuche
Me.pnlTop.Size = New System.Drawing.Size(1211, 48)
Me.pnlTop.TabIndex = 0
'
'Button3
'Label12
'
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.Image = Global.SDL.My.Resources.statistik_small
Me.Button3.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
Me.Button3.Location = New System.Drawing.Point(283, 32)
Me.Button3.Margin = New System.Windows.Forms.Padding(0)
Me.Button3.Name = "Button3"
Me.Button3.Size = New System.Drawing.Size(156, 39)
Me.Button3.TabIndex = 47
Me.Button3.Text = "SollHaben Auswertung"
Me.Button3.TextAlign = System.Drawing.ContentAlignment.MiddleRight
Me.Button3.UseVisualStyleBackColor = True
Me.Label12.AutoSize = True
Me.Label12.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.Label12.Location = New System.Drawing.Point(384, 114)
Me.Label12.Name = "Label12"
Me.Label12.Size = New System.Drawing.Size(89, 13)
Me.Label12.TabIndex = 423
Me.Label12.Text = "Zahlungsmittel"
'
'cbxZahlungsmittel
'
Me.cbxZahlungsmittel._allowedValuesFreiText = Nothing
Me.cbxZahlungsmittel._allowFreiText = False
Me.cbxZahlungsmittel._value = ""
Me.cbxZahlungsmittel.DropDownWidth = 250
Me.cbxZahlungsmittel.Font = New System.Drawing.Font("Microsoft Tai Le", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
Me.cbxZahlungsmittel.FormattingEnabled = True
Me.cbxZahlungsmittel.Location = New System.Drawing.Point(389, 130)
Me.cbxZahlungsmittel.Name = "cbxZahlungsmittel"
Me.cbxZahlungsmittel.Size = New System.Drawing.Size(98, 22)
Me.cbxZahlungsmittel.TabIndex = 424
'
'frmKassenbuchSuche
'
@@ -1546,4 +1603,6 @@ Partial Class frmKassenbuchSuche
Friend WithEvents Label24 As Label
Friend WithEvents CheckBox1 As CheckBox
Friend WithEvents Button3 As Button
Friend WithEvents Label12 As Label
Friend WithEvents cbxZahlungsmittel As VERAG_PROG_ALLGEMEIN.MyComboBox
End Class

View File

@@ -71,7 +71,7 @@ Public Class frmKassenbuchSuche
Dim sqlstr = "SELECT [JournalNr],[BelegDat],[BelegNr],CASE WHEN Belegart=1 THEN 'E' ELSE 'A' END as Belegart,[Buchungstext],([Betrag]+[Steuerbetrag]) as Brutto,[Konto],[Soll],[Haben],Steuerbetrag as Steuer,tblKassenbuch.Benutzer " &
Dim sqlstr = "SELECT [JournalNr],[BelegDat],[BelegNr],CASE WHEN Belegart=1 THEN 'E' ELSE 'A' END as Belegart,[Buchungstext],([Betrag]+[Steuerbetrag]) as Brutto,[Konto],[Soll],[Haben],Steuerbetrag as Steuer,tblKassenbuch.Benutzer, isnull([Finanzwege], '-') as ZM " &
" FROM Personal INNER JOIN tblKassenbuch ON Personal.ID = tblKassenbuch.Benutzer " &
" WHERE 1=1 "
@@ -95,6 +95,7 @@ Public Class frmKassenbuchSuche
.Columns("Buchungstext").MinimumWidth = 60
.Columns("Buchungstext").AutoSizeMode = DataGridViewAutoSizeColumnMode.Fill
.Columns("Konto").Width = 40
.Columns("ZM").Width = 40
.Columns("Soll").Width = 80
.Columns("Soll").DefaultCellStyle.Format = "C"
.Columns("Haben").Width = 80
@@ -152,6 +153,8 @@ Public Class frmKassenbuchSuche
If cboFiliale._value <> "" Then sqlstr &= " AND [FilialenNr] LIKE @FilialenNr "
If cboKassier._value <> "" Then sqlstr &= " AND [Benutzer] = @Benutzer "
If cbxZahlungsmittel._value <> "" Then sqlstr &= " AND [Finanzwege] = @Zahlungsmittel "
If txtLKWKennzeichen.Text <> "" Then sqlstr &= " AND [LKW Kennzeichen] LIKE @LKW "
' If txtSachbearbeiter.Text <> "" Then sqlstr &= " AND [Sachbearbeiter] = @Sachbearbeiter "
@@ -179,6 +182,7 @@ Public Class frmKassenbuchSuche
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("FilialenNr", cboFiliale._value))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Benutzer", cboKassier._value))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("LKW", txtLKWKennzeichen.Text.Replace("*", "%").ToUpper))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Zahlungsmittel", cbxZahlungsmittel._value))
' list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Sachbearbeiter", txtSachbearbeiter.Text))
Return list
@@ -265,6 +269,7 @@ Public Class frmKassenbuchSuche
' list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Sachbearbeiter", txtSachbearbeiter.Text))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("PreislistenNr", cboPreisliste._value))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Niederlassung", cboNiederlassung.Text))
list.Add(New VERAG_PROG_ALLGEMEIN.SQLVariable("Zahlungsmittel", cbxZahlungsmittel._value))
Return list
@@ -301,6 +306,7 @@ Public Class frmKassenbuchSuche
cboPreisliste.fillWithSQL("SELECT [PreislistenNr],[PreislistenBez] FROM [tblPreislisten] ORDER BY PreislistenBez ", False, "FMZOLL", True)
' cboStatistik_Preisliste.fillWithSQL("SELECT [PreislistenNr],[PreislistenBez] FROM [tblPreislisten] ORDER BY PreislistenBez ", False, "FMZOLL", True)
cbxZahlungsmittel.fillWithSQL("SELECT distinct([Finanzwege]) FROM [tblKassenbuch] where isnull(Finanzwege,'') <> '' ORDER BY Finanzwege ", False, "FMZOLL", True)
If VERAG_PROG_ALLGEMEIN.cBerechtignunen.CHECK_BERECHTIGUNG_bool("ADMIN", Me) Then