Auswertung Anna per Mailsender "-> "JAHRESABRECHNUNG AG-ZS" 1x jährlich am 20.2, Abgleich Kundenumsätze -> "ABGLEICH_KUNDENUEMSAETZE" -> nach OP einlesen!
This commit is contained in:
3
.gitignore
vendored
3
.gitignore
vendored
@@ -258,4 +258,5 @@ paket-files/
|
||||
|
||||
# Python Tools for Visual Studio (PTVS)
|
||||
__pycache__/
|
||||
*.pyc
|
||||
*.pyc
|
||||
/VERAG_PROG_ALLGEMEIN
|
||||
|
||||
@@ -58,6 +58,9 @@
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="VERAG_PROG_ALLGEMEIN">
|
||||
<HintPath>..\..\..\Aviso\AVISO\Aviso\bin\Debug\VERAG_PROG_ALLGEMEIN.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Import Include="Microsoft.VisualBasic" />
|
||||
@@ -456,10 +459,6 @@
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\..\SDL\SDL\VERAG_PROG_ALLGEMEIN\VERAG_PROG_ALLGEMEIN.vbproj">
|
||||
<Project>{a3b497bd-842c-4a2b-b398-ed1976849df1}</Project>
|
||||
<Name>VERAG_PROG_ALLGEMEIN</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\TELOTEK_Worker_lib\TELOTEC_Worker_lib.vbproj">
|
||||
<Project>{5b947a66-009a-4bb6-b925-f84a01045095}</Project>
|
||||
<Name>TELOTEC_Worker_lib</Name>
|
||||
|
||||
@@ -52,6 +52,9 @@
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="System.Net.Http" />
|
||||
<Reference Include="VERAG_PROG_ALLGEMEIN">
|
||||
<HintPath>..\..\..\Aviso\AVISO\Aviso\bin\Debug\VERAG_PROG_ALLGEMEIN.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Import Include="Microsoft.VisualBasic" />
|
||||
@@ -104,11 +107,5 @@
|
||||
<LastGenOutput>Settings.Designer.vb</LastGenOutput>
|
||||
</None>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\..\SDL\SDL\VERAG_PROG_ALLGEMEIN\VERAG_PROG_ALLGEMEIN.vbproj">
|
||||
<Project>{a3b497bd-842c-4a2b-b398-ed1976849df1}</Project>
|
||||
<Name>VERAG_PROG_ALLGEMEIN</Name>
|
||||
</ProjectReference>
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.VisualBasic.targets" />
|
||||
</Project>
|
||||
@@ -69,7 +69,7 @@ Module Mail
|
||||
'Exit Sub
|
||||
|
||||
'PARAM = "THYSSENKRUPP_AUSWERTUNG"
|
||||
'PARAM = "RED_BULL"
|
||||
'PARAM = "JAHRESABRECHNUNG AG-ZS"
|
||||
'PARAM = "ZF"
|
||||
|
||||
'------------------------------------------------------------------------------------
|
||||
@@ -207,6 +207,21 @@ Module Mail
|
||||
If SendEmail_RED_BULL("customs.documents.ata@redbull.com", KdNr, von, bis) Then 'für Andreas Details
|
||||
System.Console.WriteLine("Vorgang erfolgreich abgeschlossen ...")
|
||||
End If
|
||||
|
||||
Case "JAHRESABRECHNUNG AG-ZS"
|
||||
|
||||
Dim von = CDate("01.02." & Now.AddYears(-1).Year)
|
||||
Dim bis = CDate("31.01." & Now.Year)
|
||||
Dim Filialen = "'4803', '5003', '5303'"
|
||||
Dim abfertigungsart = "38"
|
||||
System.Console.WriteLine("OPTION erkannt: JAHRESAUSWERTUNG AG-ZS_ Erstellt eine jährliche Auswertung der Abfertigungen für die BH.")
|
||||
System.Console.WriteLine("Auswertung Details gestartet...")
|
||||
|
||||
If SendEmail_Jahresauwsertung_AG_ZF("as.verag.ag", Filialen, abfertigungsart, von, bis) Then
|
||||
System.Console.WriteLine("Vorgang erfolgreich abgeschlossen ...")
|
||||
End If
|
||||
|
||||
|
||||
Case "ZF"
|
||||
Dim von = CDate("01." & Now.AddMonths(-1).Month & "." & Now.AddMonths(-1).Year)
|
||||
Dim bis = CDate("01." & Now.Month & "." & Now.Year).AddDays(-1)
|
||||
@@ -568,6 +583,42 @@ Module Mail
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Function SendEmail_Jahresauwsertung_AG_ZF(Mailto As String, abfertigungsart As Integer, Filialnr As String, von As Date, bis As Date) As Boolean
|
||||
Try
|
||||
Dim excel As String = genEXCEL_ANNA(Filialnr, abfertigungsart, von, bis)
|
||||
System.Console.WriteLine("EXCEL erstellt...")
|
||||
If excel <> "" And Not excel.StartsWith("ERROR: ") Then
|
||||
|
||||
System.Console.WriteLine("Sende E-Mail...")
|
||||
|
||||
Dim Subject = "Auswertungen Jahresauswertung A-ZF "
|
||||
Dim Body = "Anbei befinden sich die Auswertungen Zollanmeldungen von " & von.ToShortDateString & " bis " & bis.ToShortDateString & "." &
|
||||
"<br><br>Erstellt am: " & Now.ToShortDateString & ", um " & Now.ToShortTimeString &
|
||||
"<br><br><br>Automatisch generiertes E-Mail. Bitte Antworten Sie nicht an dieses E-Mail." &
|
||||
"<br><br>VERAG SPEDITION AG"
|
||||
|
||||
|
||||
Dim anhenge As New List(Of String)
|
||||
anhenge.Add(excel)
|
||||
If VERAG_PROG_ALLGEMEIN.cProgramFunctions.sendMail(Mailto, Subject, Body,,, False,, "d.breimaier@verag.ag", anhenge) Then
|
||||
System.Console.WriteLine("E-Mail gesendet.")
|
||||
System.Console.WriteLine("Erfolgreich!")
|
||||
Else
|
||||
System.Console.WriteLine("ERROR BEIM SENDEN DER MAIL!")
|
||||
|
||||
End If
|
||||
|
||||
Return True
|
||||
Else
|
||||
System.Console.WriteLine(excel)
|
||||
End If
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodBase.GetCurrentMethod.Name, VERAG_PROG_ALLGEMEIN.ERROR_OP.MAIL)
|
||||
System.Console.WriteLine(ex.Message & ex.StackTrace)
|
||||
Return False
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Function SendEmail_ZF(Mailto As String, KdNr As String, von As Date, bis As Date) As Boolean
|
||||
Try
|
||||
Dim excel As String = genEXCEL_ZF(KdNr, von, bis)
|
||||
@@ -1425,6 +1476,36 @@ Module Mail
|
||||
End Function
|
||||
|
||||
|
||||
Public Function genEXCEL_ANNA(FilialenNr As String, abfertigungsart As Integer, von As Date, bis As Date) As String
|
||||
Try
|
||||
|
||||
Dim sqlstr As String = ""
|
||||
|
||||
sqlstr &= "SELECT count(*) as Anzahl,FilialenNr,case when KE.Veranlagungskunde = 1 Then adr.[Name 1] else adre.[Name 1] ENd as Kunde "
|
||||
sqlstr &= "FROM [VERAG].[dbo].[Speditionsbuch] as SP "
|
||||
sqlstr &= "left join [tblKundenErweitert] as KE on KE.kde_KundenNr = SP.EmpfängerKundenNr "
|
||||
sqlstr &= "left join adressen as adr on adr.AdressenNr = SP.EmpfängerKundenNr "
|
||||
sqlstr &= "left join [tblKundenErweitert] as KA on KA.kde_KundenNr = SP.VermittlerKundenNr "
|
||||
sqlstr &= "left join adressen as adre on adre.AdressenNr = SP.VermittlerKundenNr "
|
||||
sqlstr &= "where Abfertigungsart = " & abfertigungsart & " and Abfertigungsdatum between '" & von.ToShortDateString & "' and '" & bis.ToShortDateString & "' and FilialenNr in (" & FilialenNr & ") and (Ke.Veranlagungskunde = 1 or KA.Veranlagungskunde = 1) "
|
||||
sqlstr &= "group by case when KE.Veranlagungskunde = 1 Then adr.[Name 1] else adre.[Name 1] ENd, FilialenNr order by Kunde"
|
||||
|
||||
|
||||
Dim dt As DataTable = loadDgvBySqlFMZOLL(sqlstr)
|
||||
|
||||
|
||||
Dim filepath = VERAG_PROG_ALLGEMEIN.cProgramFunctions.genExcelFromDT_NEW(dt,,,,, False, "Report Data_" & von.ToShortDateString & "-" & bis.ToShortDateString)
|
||||
If filepath = "" Then Return "ERROR 01: Fehler beim Erzeugen des XLS."
|
||||
|
||||
Return filepath
|
||||
Catch ex As System.Exception
|
||||
' MsgBox(ex.Message)
|
||||
Return "ERROR 02: " & ex.Message & vbNewLine & ex.StackTrace
|
||||
End Try
|
||||
|
||||
End Function
|
||||
|
||||
|
||||
Public Function genEXCEL_ZF(KdNr As String, von As Date, bis As Date) As String
|
||||
Try
|
||||
|
||||
|
||||
@@ -28,6 +28,7 @@ Public Class usrCntlMitarbeiter
|
||||
Try
|
||||
' Me.Size = My.Settings.frmMainSize
|
||||
' Me.Location = My.Settings.frmMainPosition
|
||||
Catch ex As Exception
|
||||
Catch ex As Exception
|
||||
'nix tun - Standardgröße wird somit automatisch gesetzt
|
||||
End Try
|
||||
|
||||
@@ -75,31 +75,10 @@
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\..\AVISO\Aviso\packages\DocumentFormat.OpenXml.2.7.2\lib\net46\DocumentFormat.OpenXml.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Dynamsoft.Forms.Viewer, Version=7.0.0.320, Culture=neutral, PublicKeyToken=298ad97013b423eb, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>C:\Program Files (x86)\Dynamsoft\Dynamic .NET TWAIN 7.0\Redistributable\Assembly\For .NETFramework 4.0\Dynamsoft.Forms.Viewer.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Dynamsoft.ImageCore, Version=7.0.0.3020, Culture=neutral, PublicKeyToken=298ad97013b423eb, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>C:\Program Files (x86)\Dynamsoft\Dynamic .NET TWAIN 7.0\Redistributable\Assembly\For .NETFramework 4.0\Dynamsoft.ImageCore.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Dynamsoft.PDF, Version=7.0.0.320, Culture=neutral, PublicKeyToken=298ad97013b423eb, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>C:\Program Files (x86)\Dynamsoft\Dynamic .NET TWAIN 7.0\Redistributable\Assembly\For .NETFramework 4.0\Dynamsoft.PDF.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Dynamsoft.Twain, Version=7.0.0.320, Culture=neutral, PublicKeyToken=298ad97013b423eb, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>C:\Program Files (x86)\Dynamsoft\Dynamic .NET TWAIN 7.0\Redistributable\Assembly\For .NETFramework 4.0\Dynamsoft.Twain.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Ghostscript.NET, Version=1.2.1.0, Culture=neutral, PublicKeyToken=f85051de34525b59, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\..\dll\Ghostscript.NET.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="GrapeCity.ActiveReports.Chart.v12, Version=12.2.13986.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" />
|
||||
<Reference Include="GrapeCity.ActiveReports.Diagnostics.v12, Version=12.2.13986.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" />
|
||||
<Reference Include="GrapeCity.ActiveReports.Document.v12, Version=12.2.13986.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" />
|
||||
<Reference Include="GrapeCity.ActiveReports.Extensibility.v12, Version=12.2.13986.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" />
|
||||
<Reference Include="GrapeCity.ActiveReports.v12, Version=12.2.13986.0, Culture=neutral, PublicKeyToken=cc4967777c49a3ff" />
|
||||
<Reference Include="itextsharp, Version=5.5.5.0, Culture=neutral, PublicKeyToken=8354ae6d2174ddca, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\..\dll\itextsharp.dll</HintPath>
|
||||
@@ -129,6 +108,9 @@
|
||||
<Reference Include="System.Core" />
|
||||
<Reference Include="System.Xml.Linq" />
|
||||
<Reference Include="System.Data.DataSetExtensions" />
|
||||
<Reference Include="VERAG_PROG_ALLGEMEIN">
|
||||
<HintPath>..\..\..\Aviso\AVISO\Aviso\bin\Debug\VERAG_PROG_ALLGEMEIN.dll</HintPath>
|
||||
</Reference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Import Include="Microsoft.VisualBasic" />
|
||||
@@ -304,10 +286,6 @@
|
||||
<None Include="Resources\start.png" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\..\..\SDL\SDL\VERAG_PROG_ALLGEMEIN\VERAG_PROG_ALLGEMEIN.vbproj">
|
||||
<Project>{a3b497bd-842c-4a2b-b398-ed1976849df1}</Project>
|
||||
<Name>VERAG_PROG_ALLGEMEIN</Name>
|
||||
</ProjectReference>
|
||||
<ProjectReference Include="..\cNCTSPartnerWorker\NCTSPartnerWorker.vbproj">
|
||||
<Project>{2bbd7643-82a1-481f-a014-eb7fcdeed3b5}</Project>
|
||||
<Name>NCTSPartnerWorker</Name>
|
||||
|
||||
81
initATLASAufschubkonten/frmStartOptions.Designer.vb
generated
81
initATLASAufschubkonten/frmStartOptions.Designer.vb
generated
@@ -148,6 +148,8 @@ Partial Class frmStartOptions
|
||||
Me.PictureBox15 = New System.Windows.Forms.PictureBox()
|
||||
Me.PictureBox14 = New System.Windows.Forms.PictureBox()
|
||||
Me.TabPage3 = New System.Windows.Forms.TabPage()
|
||||
Me.LinkLabel50 = New System.Windows.Forms.LinkLabel()
|
||||
Me.Label26 = New System.Windows.Forms.Label()
|
||||
Me.LinkLabel39 = New System.Windows.Forms.LinkLabel()
|
||||
Me.LinkLabel40 = New System.Windows.Forms.LinkLabel()
|
||||
Me.Label22 = New System.Windows.Forms.Label()
|
||||
@@ -202,8 +204,8 @@ Partial Class frmStartOptions
|
||||
Me.lblRoutineManager = New System.Windows.Forms.Label()
|
||||
Me.txtGJ_UNISPED = New VERAG_PROG_ALLGEMEIN.MyTextBox()
|
||||
Me.Button21 = New System.Windows.Forms.Button()
|
||||
Me.LinkLabel50 = New System.Windows.Forms.LinkLabel()
|
||||
Me.Label26 = New System.Windows.Forms.Label()
|
||||
Me.Button22 = New System.Windows.Forms.Button()
|
||||
Me.PictureBox22 = New System.Windows.Forms.PictureBox()
|
||||
Me.pnl.SuspendLayout()
|
||||
CType(Me.piceZollAnh, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.tbcntr.SuspendLayout()
|
||||
@@ -235,12 +237,15 @@ Partial Class frmStartOptions
|
||||
CType(Me.PictureBox11, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.PictureBox10, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.PictureBox9, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
CType(Me.PictureBox22, System.ComponentModel.ISupportInitialize).BeginInit()
|
||||
Me.SuspendLayout()
|
||||
'
|
||||
'pnl
|
||||
'
|
||||
Me.pnl.BackColor = System.Drawing.Color.White
|
||||
Me.pnl.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle
|
||||
Me.pnl.Controls.Add(Me.PictureBox22)
|
||||
Me.pnl.Controls.Add(Me.Button22)
|
||||
Me.pnl.Controls.Add(Me.LinkLabel48)
|
||||
Me.pnl.Controls.Add(Me.cbxVermerk)
|
||||
Me.pnl.Controls.Add(Me.cbxDatevTest)
|
||||
@@ -506,9 +511,9 @@ Partial Class frmStartOptions
|
||||
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.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.Button13.Location = New System.Drawing.Point(559, 343)
|
||||
Me.Button13.Location = New System.Drawing.Point(509, 344)
|
||||
Me.Button13.Name = "Button13"
|
||||
Me.Button13.Size = New System.Drawing.Size(197, 24)
|
||||
Me.Button13.Size = New System.Drawing.Size(197, 22)
|
||||
Me.Button13.TabIndex = 61
|
||||
Me.Button13.Text = "OP --> VERAG"
|
||||
Me.Button13.UseVisualStyleBackColor = True
|
||||
@@ -518,9 +523,9 @@ Partial Class frmStartOptions
|
||||
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.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.Button12.Location = New System.Drawing.Point(559, 320)
|
||||
Me.Button12.Location = New System.Drawing.Point(509, 321)
|
||||
Me.Button12.Name = "Button12"
|
||||
Me.Button12.Size = New System.Drawing.Size(197, 24)
|
||||
Me.Button12.Size = New System.Drawing.Size(197, 22)
|
||||
Me.Button12.TabIndex = 60
|
||||
Me.Button12.Text = "Risiko --> Syska"
|
||||
Me.Button12.UseVisualStyleBackColor = True
|
||||
@@ -565,9 +570,9 @@ Partial Class frmStartOptions
|
||||
Me.Button10.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.Button10.ForeColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
|
||||
Me.Button10.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.Button10.Location = New System.Drawing.Point(559, 374)
|
||||
Me.Button10.Location = New System.Drawing.Point(509, 375)
|
||||
Me.Button10.Name = "Button10"
|
||||
Me.Button10.Size = New System.Drawing.Size(197, 24)
|
||||
Me.Button10.Size = New System.Drawing.Size(197, 22)
|
||||
Me.Button10.TabIndex = 57
|
||||
Me.Button10.Text = "TESTBuchungen --> Syska"
|
||||
Me.Button10.UseVisualStyleBackColor = True
|
||||
@@ -1870,6 +1875,27 @@ Partial Class frmStartOptions
|
||||
Me.TabPage3.Text = "Partner-Systeme"
|
||||
Me.TabPage3.UseVisualStyleBackColor = True
|
||||
'
|
||||
'LinkLabel50
|
||||
'
|
||||
Me.LinkLabel50.AutoSize = True
|
||||
Me.LinkLabel50.LinkColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
|
||||
Me.LinkLabel50.Location = New System.Drawing.Point(416, 152)
|
||||
Me.LinkLabel50.Name = "LinkLabel50"
|
||||
Me.LinkLabel50.Size = New System.Drawing.Size(54, 13)
|
||||
Me.LinkLabel50.TabIndex = 34
|
||||
Me.LinkLabel50.TabStop = True
|
||||
Me.LinkLabel50.Text = "Send Mail"
|
||||
'
|
||||
'Label26
|
||||
'
|
||||
Me.Label26.AutoSize = True
|
||||
Me.Label26.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.Label26.Location = New System.Drawing.Point(416, 125)
|
||||
Me.Label26.Name = "Label26"
|
||||
Me.Label26.Size = New System.Drawing.Size(38, 13)
|
||||
Me.Label26.TabIndex = 33
|
||||
Me.Label26.Text = "RMC:"
|
||||
'
|
||||
'LinkLabel39
|
||||
'
|
||||
Me.LinkLabel39.AutoSize = True
|
||||
@@ -2529,26 +2555,28 @@ Partial Class frmStartOptions
|
||||
Me.Button21.Text = "AAS Sendung 24h"
|
||||
Me.Button21.UseVisualStyleBackColor = True
|
||||
'
|
||||
'LinkLabel50
|
||||
'Button22
|
||||
'
|
||||
Me.LinkLabel50.AutoSize = True
|
||||
Me.LinkLabel50.LinkColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
|
||||
Me.LinkLabel50.Location = New System.Drawing.Point(416, 152)
|
||||
Me.LinkLabel50.Name = "LinkLabel50"
|
||||
Me.LinkLabel50.Size = New System.Drawing.Size(54, 13)
|
||||
Me.LinkLabel50.TabIndex = 34
|
||||
Me.LinkLabel50.TabStop = True
|
||||
Me.LinkLabel50.Text = "Send Mail"
|
||||
Me.Button22.FlatStyle = System.Windows.Forms.FlatStyle.Flat
|
||||
Me.Button22.ForeColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer))
|
||||
Me.Button22.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft
|
||||
Me.Button22.Location = New System.Drawing.Point(718, 342)
|
||||
Me.Button22.Name = "Button22"
|
||||
Me.Button22.Size = New System.Drawing.Size(105, 24)
|
||||
Me.Button22.TabIndex = 78
|
||||
Me.Button22.Text = "Kd-Umsätze akt."
|
||||
Me.Button22.UseVisualStyleBackColor = True
|
||||
'
|
||||
'Label26
|
||||
'PictureBox22
|
||||
'
|
||||
Me.Label26.AutoSize = True
|
||||
Me.Label26.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte))
|
||||
Me.Label26.Location = New System.Drawing.Point(416, 125)
|
||||
Me.Label26.Name = "Label26"
|
||||
Me.Label26.Size = New System.Drawing.Size(38, 13)
|
||||
Me.Label26.TabIndex = 33
|
||||
Me.Label26.Text = "RMC:"
|
||||
Me.PictureBox22.BackgroundImage = CType(resources.GetObject("PictureBox22.BackgroundImage"), System.Drawing.Image)
|
||||
Me.PictureBox22.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Zoom
|
||||
Me.PictureBox22.Location = New System.Drawing.Point(830, 344)
|
||||
Me.PictureBox22.Name = "PictureBox22"
|
||||
Me.PictureBox22.Size = New System.Drawing.Size(18, 18)
|
||||
Me.PictureBox22.TabIndex = 84
|
||||
Me.PictureBox22.TabStop = False
|
||||
Me.PictureBox22.Visible = False
|
||||
'
|
||||
'frmStartOptions
|
||||
'
|
||||
@@ -2599,6 +2627,7 @@ Partial Class frmStartOptions
|
||||
CType(Me.PictureBox11, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.PictureBox10, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.PictureBox9, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
CType(Me.PictureBox22, System.ComponentModel.ISupportInitialize).EndInit()
|
||||
Me.ResumeLayout(False)
|
||||
|
||||
End Sub
|
||||
@@ -2782,4 +2811,6 @@ Partial Class frmStartOptions
|
||||
Friend WithEvents LinkLabel49 As LinkLabel
|
||||
Friend WithEvents LinkLabel50 As LinkLabel
|
||||
Friend WithEvents Label26 As Label
|
||||
Friend WithEvents Button22 As Button
|
||||
Friend WithEvents PictureBox22 As PictureBox
|
||||
End Class
|
||||
|
||||
@@ -118,6 +118,30 @@
|
||||
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
|
||||
</resheader>
|
||||
<assembly alias="System.Drawing" name="System.Drawing, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
|
||||
<data name="PictureBox22.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAABGdBTUEAALGPC/xhBQAABEhJREFUSEtj
|
||||
oDZg4WThlrSSdLPOtc53zHaMl5SUZGBnZ4fKUhMwMjCK6IloGhUYZdn32a/wX+Z/0Ge2z0L9eH0rQVVB
|
||||
QSZ2JqhCKgEBNQFFoyKjnPAj4cdjz8d+jb8U/z/iaMR9z2WeE3XSdByEdYWFGVkYGaHKKQdWTVYF4YfC
|
||||
j8VdjPsHwiALYezo89HTzWrNHNj42VigyikHDv0OC2POxrwDWYSOgZY+DNoRNMV5urMdVDn5gFOUU0rJ
|
||||
VynOd7XvBSwW/QHiHx4LPPYDQ6DUpMzEEKqNPMDKw8on5ywXBHT9w+hT0d/QLPsefTr6Rei+0Iuqwaox
|
||||
XGJcElBt5AMFT4UIYDBtjzkT8zPuQtxfNAuv+G/wn6CdoG3Bp8AnysjMSH78MXMyc0tZSbnZtNksDtsf
|
||||
9hJoODiRgC26EPcD6IDbPit9Oo3yjWz4Ffm5gXmTGaqVPMAuwC6il6ZXgx5vsedif4YfDH/kNsdtIlDe
|
||||
VlRflDo5HpeFkUcj33jM89gqbigux8bNBlVNIeCR4pFX9ldO8F7qfTLyWORHmGUx52N+2/XYrRTRFTFh
|
||||
42PjAMYZVAcOwMzBzA2MXHUFDwVLGXsZDS4JLjZ0TeyC7CLghDLVeWvU8ahPyL7z3+u/STNdMwSqFD8A
|
||||
pSBeOV41rTitYr/1ftNd57jmKnorygKDjpUBqQgU1BA0NKsym4JsESifAfFzyxmWXhKeEqxQpfgBpxin
|
||||
lEqgSnLI3pBn0Wei30aeiNzlucQzWdxEXBKY1+DJGYeF12IuxBTJe8srsfAQkfKBQckFzJgp7vPdD4KS
|
||||
d9ylOJAhL4AF73aHCQ5RwKpGjomViZWVl1VAP0u/wXeN70WYZbEXYi/7b/Lv0c3Q1eGR5eGBGokfKLgp
|
||||
hALjZBuyq0EYaOkHoIErzWvN/cWMxSSAcSoLTO57oXK/gPhp4PbAqUAfO7MLsbMBHUVcTQD2FVLGRbIQ
|
||||
LA5MfdNdZrnYolkIcswSs0ozL2Aw80KNIg5I20h7ApN5lGWdZQfQoPtAA8F1GZLFD4HVznGQZUD6NUgs
|
||||
8kjka5t2m25pW2kzFm4yShFgvuGVMJEwNq0wrXSd6bopeGfwA2RLkTHIUrfZbnvkXOWCQYkNagT5QNZZ
|
||||
NsCu225Z9MnoD8By8TfQEkQ5eTHuJzDRHAMmnkJ2EXYhqBbKADCIeIGZ29t9nvvSqJNRL4AW/UKy8L7P
|
||||
ap8Juum6BsBCgHotI25JbgkZBxkHtVC1JGDc7Qa2UX4CE8n3oJ1B64GpMlpYR5ifmZ2Zyq0iKFANUk3x
|
||||
WOhxEFgYvLZus64EJhQtqBTtALDEsQ/aHnRf3FTcASpEWwBsbQkBLQW1uqiTUJABFxcXg7y8PJupqSm/
|
||||
nZ2diL29vSgyBooJm5ub88nKyrIC1VLezgQ2zRk9PT0F6urqVCdNmmQwbdo0Y2Q8efJk3ebmZkVXV1de
|
||||
CQkJEjM9AwMAOTMC2xlgxuQAAAAASUVORK5CYII=
|
||||
</value>
|
||||
</data>
|
||||
<data name="piceZollAnh.BackgroundImage" type="System.Drawing.Bitmap, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
|
||||
<value>
|
||||
iVBORw0KGgoAAAANSUhEUgAAABwAAAAcCAYAAAByDd+UAAAABGdBTUEAALGPC/xhBQAABEhJREFUSEtj
|
||||
|
||||
@@ -506,6 +506,13 @@ Public Class frmStartOptions
|
||||
AddHandler fmTTR.FormClosed, AddressOf closeMe
|
||||
closeMe()
|
||||
|
||||
Case "ABGLEICH_KUNDENUEMSAETZE"
|
||||
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
||||
Dim lastyears = 2
|
||||
If DELETE_Kundenumsaetze(lastyears) Then
|
||||
INSERT_Kundenumsaetze(lastyears)
|
||||
End If
|
||||
|
||||
'------------------------------
|
||||
Case Else
|
||||
'Nur bei manuellem Start wird der fehler ausgegeben
|
||||
@@ -4065,9 +4072,7 @@ Public Class frmStartOptions
|
||||
|
||||
Private Sub cbxTestsystem_CheckedChanged(sender As Object, e As EventArgs) Handles cbxTestsystem.CheckedChanged
|
||||
If tbcntr.SelectedIndex = 3 Then
|
||||
|
||||
checkTBLandTWLNr()
|
||||
|
||||
End If
|
||||
End Sub
|
||||
|
||||
@@ -4086,4 +4091,61 @@ Public Class frmStartOptions
|
||||
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
||||
sendWOELFL_USTVAntraege("al@verag.ag")
|
||||
End Sub
|
||||
|
||||
Function INSERT_Kundenumsaetze(insertLastYears As Integer) As Boolean
|
||||
Try
|
||||
|
||||
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
|
||||
|
||||
Dim sqltext = "INSERT INTO tblKundenumsatz ( KundenNr, Firma_ID, Jahr, steuerpflichtig, steuerfrei, Nettoumsatz, MwSt, Bruttoumsatz, Währung, Rechnungen, Gutschriften, Datum, Nummer )
|
||||
SELECT RechnungsKundenNr AS KundenNr,
|
||||
Firma_ID,
|
||||
Year([Rechnungsdatum]) AS Jahr,
|
||||
Sum(SteuerpflichtigerBetragLokal) AS steuerpflichtig,
|
||||
Sum(SteuerfreierBetragLokal) AS steuerfrei,
|
||||
Sum(SteuerfreierBetragLokal) AS Nettoumsatz,
|
||||
Sum(SteuerbetragLokal) AS MwSt,
|
||||
Sum(RechnungsbetragLokal) AS Bruttoumsatz,
|
||||
WährungLokal AS Währung,
|
||||
sum(Case when [BelegartenNr]=70 Then 1 else 0 End) as Rechnungen,
|
||||
sum(Case when [BelegartenNr]=71 Then 1 else 0 End) as Gutschriften,
|
||||
Max(Rechnungsdatum) AS Datum,
|
||||
Max(Rechnungsnummer) AS Nummer
|
||||
FROM [VERAG].[dbo].[tblTrdinInvoice]
|
||||
where Year([Rechnungsdatum]) > (year(getdate()) - " & insertLastYears & ")
|
||||
GROUP BY RechnungsKundenNr, Firma_ID, Year([Rechnungsdatum]), WährungLokal
|
||||
ORDER BY RechnungsKundenNr, Firma_ID, Year([Rechnungsdatum]) DESC , WährungLokal"
|
||||
|
||||
Return SQL.doSQL(sqltext, "FMZOLL")
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodBase.GetCurrentMethod.Name, VERAG_PROG_ALLGEMEIN.ERROR_OP.MAIL)
|
||||
|
||||
Return False
|
||||
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Function DELETE_Kundenumsaetze(deleteLastYears As Integer) As Boolean
|
||||
Try
|
||||
|
||||
Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL
|
||||
Return SQL.doSQL("DELETE from tblKundenumsatz where Jahr > (year(getdate()) -" & deleteLastYears & ")", "FMZOLL")
|
||||
|
||||
Catch ex As Exception
|
||||
VERAG_PROG_ALLGEMEIN.cErrorHandler.ERR(ex.Message, ex.StackTrace, System.Reflection.MethodBase.GetCurrentMethod.Name, VERAG_PROG_ALLGEMEIN.ERROR_OP.MAIL)
|
||||
|
||||
Return False
|
||||
|
||||
End Try
|
||||
End Function
|
||||
|
||||
Private Sub Button22_Click(sender As Object, e As EventArgs) Handles Button22.Click
|
||||
VERAG_PROG_ALLGEMEIN.cAllgemein.TESTSYSTEM = False
|
||||
Dim lastyears = 2
|
||||
Dim ok = False
|
||||
If DELETE_Kundenumsaetze(lastyears) Then
|
||||
ok = INSERT_Kundenumsaetze(lastyears)
|
||||
End If
|
||||
showPic(ok, PictureBox22)
|
||||
End Sub
|
||||
End Class
|
||||
Reference in New Issue
Block a user