diff --git a/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb b/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb index c7cceb8..2e6ebf7 100644 --- a/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb +++ b/Aviso/frmGesamtsicherheitenMenuNEU.Designer.vb @@ -25,6 +25,8 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.components = New System.ComponentModel.Container() Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmGesamtsicherheitenMenuNEU)) Me.dgvListe = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) + Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components) + Me.ExportCSVToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.Panel1 = New System.Windows.Forms.Panel() Me.btnOpenOver85Days = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.txtDatBis = New VERAG_PROG_ALLGEMEIN.MyTextBox() @@ -61,11 +63,9 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblSaldo = New System.Windows.Forms.Label() Me.lblZollsatz = New System.Windows.Forms.Label() Me.lblReferenzwert = New System.Windows.Forms.Label() - Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components) - Me.ExportCSVToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() CType(Me.dgvListe, System.ComponentModel.ISupportInitialize).BeginInit() - Me.Panel1.SuspendLayout() Me.ContextMenuStrip1.SuspendLayout() + Me.Panel1.SuspendLayout() Me.SuspendLayout() ' 'dgvListe @@ -83,6 +83,18 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.dgvListe.Size = New System.Drawing.Size(606, 408) Me.dgvListe.TabIndex = 1 ' + 'ContextMenuStrip1 + ' + Me.ContextMenuStrip1.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.ExportCSVToolStripMenuItem}) + Me.ContextMenuStrip1.Name = "ContextMenuStrip1" + Me.ContextMenuStrip1.Size = New System.Drawing.Size(133, 26) + ' + 'ExportCSVToolStripMenuItem + ' + Me.ExportCSVToolStripMenuItem.Name = "ExportCSVToolStripMenuItem" + Me.ExportCSVToolStripMenuItem.Size = New System.Drawing.Size(132, 22) + Me.ExportCSVToolStripMenuItem.Text = "Export CSV" + ' 'Panel1 ' Me.Panel1.BackColor = System.Drawing.Color.FromArgb(CType(CType(0, Byte), Integer), CType(CType(54, Byte), Integer), CType(CType(128, Byte), Integer)) @@ -607,9 +619,9 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblSaldo.ForeColor = System.Drawing.Color.Honeydew Me.lblSaldo.Location = New System.Drawing.Point(398, 21) Me.lblSaldo.Name = "lblSaldo" - Me.lblSaldo.Size = New System.Drawing.Size(147, 24) + Me.lblSaldo.Size = New System.Drawing.Size(82, 24) Me.lblSaldo.TabIndex = 1 - Me.lblSaldo.Text = "Saldo: €80.000" + Me.lblSaldo.Text = "Saldo: -" ' 'lblZollsatz ' @@ -619,9 +631,9 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblZollsatz.ForeColor = System.Drawing.Color.Honeydew Me.lblZollsatz.Location = New System.Drawing.Point(399, 83) Me.lblZollsatz.Name = "lblZollsatz" - Me.lblZollsatz.Size = New System.Drawing.Size(85, 16) + Me.lblZollsatz.Size = New System.Drawing.Size(63, 16) Me.lblZollsatz.TabIndex = 9 - Me.lblZollsatz.Text = "Zollsatz: 12%" + Me.lblZollsatz.Text = "Zollsatz: -" ' 'lblReferenzwert ' @@ -631,21 +643,9 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.lblReferenzwert.ForeColor = System.Drawing.Color.Honeydew Me.lblReferenzwert.Location = New System.Drawing.Point(399, 56) Me.lblReferenzwert.Name = "lblReferenzwert" - Me.lblReferenzwert.Size = New System.Drawing.Size(136, 16) + Me.lblReferenzwert.Size = New System.Drawing.Size(95, 16) Me.lblReferenzwert.TabIndex = 6 - Me.lblReferenzwert.Text = "Referenzwert: €80.000" - ' - 'ContextMenuStrip1 - ' - Me.ContextMenuStrip1.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.ExportCSVToolStripMenuItem}) - Me.ContextMenuStrip1.Name = "ContextMenuStrip1" - Me.ContextMenuStrip1.Size = New System.Drawing.Size(133, 26) - ' - 'ExportCSVToolStripMenuItem - ' - Me.ExportCSVToolStripMenuItem.Name = "ExportCSVToolStripMenuItem" - Me.ExportCSVToolStripMenuItem.Size = New System.Drawing.Size(132, 22) - Me.ExportCSVToolStripMenuItem.Text = "Export CSV" + Me.lblReferenzwert.Text = "Referenzwert: -" ' 'frmGesamtsicherheitenMenuNEU ' @@ -661,9 +661,9 @@ Partial Class frmGesamtsicherheitenMenuNEU Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen Me.Text = "frmGesSichMenu" CType(Me.dgvListe, System.ComponentModel.ISupportInitialize).EndInit() + Me.ContextMenuStrip1.ResumeLayout(False) Me.Panel1.ResumeLayout(False) Me.Panel1.PerformLayout() - Me.ContextMenuStrip1.ResumeLayout(False) Me.ResumeLayout(False) End Sub diff --git a/Aviso/frmGesamtsicherheitenMenuNEU.vb b/Aviso/frmGesamtsicherheitenMenuNEU.vb index 225211b..c618194 100644 --- a/Aviso/frmGesamtsicherheitenMenuNEU.vb +++ b/Aviso/frmGesamtsicherheitenMenuNEU.vb @@ -5,7 +5,7 @@ Public Class frmGesamtsicherheitenMenuNEU Public SQL As New VERAG_PROG_ALLGEMEIN.SQL Dim GesSichRef As VERAG_PROG_ALLGEMEIN.cGesamtsicherheitsReferenz - Public dt As DataTable + Public dataTable As DataTable Public Property Standort As String = "" @@ -14,10 +14,18 @@ Public Class frmGesamtsicherheitenMenuNEU cbxWarenort.fillWithSQL("SELECT [grz_Grenzstelle], [grz_Bezeichnung] FROM [tblGrenzstelle] WHERE [grz_Aktiv] ='1' AND [grz_Warenort] ='1' ORDER BY [grz_Reihenfolge] ", True, "AVISO", True) Me.Text = "Gesamtsicherheiten " & Standort frmHauptfenster.EnableDoubleBuffered(dgvListe) + GesSichRef = New VERAG_PROG_ALLGEMEIN.cGesamtsicherheitsReferenz(Standort) + If GesSichRef.hasEntry = False Then + MsgBox("Für den Standort " & Standort & " wurde keine Referenz hingerlegt!") + Exit Sub + + End If lblSaldo.Text = "Saldo: €" & Decimal.Parse(GesSichRef.CalcSaldo()).ToString("N") + + txtDatVon.Text = Now.ToShortDateString txtDatBis.Text = Now.ToShortDateString @@ -31,11 +39,6 @@ Public Class frmGesamtsicherheitenMenuNEU End If End If - - - - 'txtDatVon.Text = Date.Today.AddDays(-30).ToString("dd.MM.yyyy") - 'txtDatBis.Text = Date.Today.ToString("dd.MM.yyyy") ShowStandort() LoadDGV() End Sub @@ -70,7 +73,7 @@ Public Class frmGesamtsicherheitenMenuNEU ) as tb1 left join [tblGesamtsicherheit] as tb2 on tb1.ding = tb2.gs_gsnr) as meh group by gs_gsnr) as meh2 Where gs_standort = '" & Standort & "' " & sqladdon & " AND gs_datum > '" & Date.Parse(txtDatVon.Text) & "' - AND gs_datum < '" & Date.Parse(txtDatBis.Text).AddDays(1).AddSeconds(-1) & "'" + AND gs_datum < '" & Date.Parse(txtDatBis.Text).AddDays(1).AddSeconds(-1) & "' ORDER BY gs_gsnr" dgvListe.SET_SQL(sqlstring, "AVISO") dgvListe.LOAD() @@ -99,9 +102,9 @@ Public Class frmGesamtsicherheitenMenuNEU If dgvListe.Rows.Count = 0 Then Exit Function - dt = New DataTable() - dt.Columns.Add("gs_gsnr", GetType(Integer)) - dt.Columns.Add("gs_isOpen", GetType(Boolean)) + dataTable = New DataTable() + dataTable.Columns.Add("gs_gsnr", GetType(Integer)) + dataTable.Columns.Add("gs_isOpen", GetType(Boolean)) @@ -109,9 +112,9 @@ Public Class frmGesamtsicherheitenMenuNEU For Each row As DataGridViewRow In dgvListe.Rows If row.Cells("gs_SicherheitsSaldo").Value <> 0 Then - dt.Rows.Add(row.Cells("gs_gsnr").Value, True) + dataTable.Rows.Add(row.Cells("gs_gsnr").Value, True) Else - dt.Rows.Add(row.Cells("gs_gsnr").Value, False) + dataTable.Rows.Add(row.Cells("gs_gsnr").Value, False) End If Next @@ -135,8 +138,7 @@ Public Class frmGesamtsicherheitenMenuNEU End Function Public Sub ShowStandort() - 'lblReferenzwert.Text = "Referenzwert: €" & GesSichRef.gsr_referenzwert.ToString("N") - lblReferenzwert.Text = "Referenzwert: €" & GesSichRef.gsr_referenzwert.ToString() + lblReferenzwert.Text = "Referenzwert: €" & CDbl(GesSichRef.gsr_referenzwert).ToString("N") lblZollsatz.Text = "Zollsatz: " & GesSichRef.gsr_zollsatz & "%" lblSaldo.Text = "Saldo: €" & Decimal.Parse(GesSichRef.CalcSaldo()).ToString("N") End Sub @@ -155,7 +157,7 @@ Public Class frmGesamtsicherheitenMenuNEU .FilialNummer = dgvListe.CurrentRow.Cells("gs_filialenNr").Value .Abfertigungsnummer = dgvListe.CurrentRow.Cells("gs_abfertigungsNr").Value .warenortID = dgvListe.CurrentRow.Cells("gs_warenort").Value - .dt = Me.dt + .dataTable = Me.dataTable End With AddHandler frm.FormClosing, Function() @@ -174,7 +176,7 @@ Public Class frmGesamtsicherheitenMenuNEU .Standort = Me.Standort .datum = Date.Now .Neu = True - .dt = Me.dt + .dataTable = Me.dataTable End With AddHandler frm.FormClosing, Function() GesSichRef.CalcSaldo() diff --git a/Aviso/frmGesamtsicherheitenNEU.Designer.vb b/Aviso/frmGesamtsicherheitenNEU.Designer.vb index f1c8022..f7cc843 100644 --- a/Aviso/frmGesamtsicherheitenNEU.Designer.vb +++ b/Aviso/frmGesamtsicherheitenNEU.Designer.vb @@ -29,18 +29,12 @@ Partial Class frmGesamtsicherheitenNEU Dim DataGridViewCellStyle4 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim DataGridViewCellStyle5 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Dim resources As System.ComponentModel.ComponentResourceManager = New System.ComponentModel.ComponentResourceManager(GetType(frmGesamtsicherheitenNEU)) - Me.dgvGesamtsicherheit = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.ContextMenuStrip1 = New System.Windows.Forms.ContextMenuStrip(Me.components) Me.ClosedErzeugenToolStripMenuItem = New System.Windows.Forms.ToolStripMenuItem() Me.Panel2 = New System.Windows.Forms.Panel() - Me.pnlSummeGesPos = New System.Windows.Forms.Panel() - Me.txtPosSicherheitsbGes = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.txtPosWarenwertGes = New VERAG_PROG_ALLGEMEIN.MyTextBox() - Me.txtPosAnzalPosGes = New System.Windows.Forms.TextBox() - Me.Label29 = New System.Windows.Forms.Label() - Me.Label28 = New System.Windows.Forms.Label() - Me.Label22 = New System.Windows.Forms.Label() Me.panOverlay = New System.Windows.Forms.Panel() + Me.txtlkwIdSearch = New VERAG_PROG_ALLGEMEIN.MySearchBox() + Me.Label23 = New System.Windows.Forms.Label() Me.cboWarenort = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.lblWarenort = New System.Windows.Forms.Label() Me.cboFiliale = New VERAG_PROG_ALLGEMEIN.MyComboBox() @@ -51,16 +45,21 @@ Partial Class frmGesamtsicherheitenNEU Me.Label17 = New System.Windows.Forms.Label() Me.Label16 = New System.Windows.Forms.Label() Me.btnClosePanOverlay = New VERAG_PROG_ALLGEMEIN.FlatButton() + Me.dgvGesamtsicherheit = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.dgvSicherheitsPos = New VERAG_PROG_ALLGEMEIN.MyDatagridview(Me.components) Me.pnlSummeGes = New System.Windows.Forms.Panel() + Me.txtPosSicherheitsbGes = New VERAG_PROG_ALLGEMEIN.MyTextBox() Me.txtSicherheitsbGes = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.Label28 = New System.Windows.Forms.Label() + Me.txtPosWarenwertGes = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.Label29 = New System.Windows.Forms.Label() Me.txtWarenwertGes = New VERAG_PROG_ALLGEMEIN.MyTextBox() + Me.txtPosAnzalPosGes = New System.Windows.Forms.TextBox() Me.txtAnzalPosGes = New System.Windows.Forms.TextBox() Me.Label27 = New System.Windows.Forms.Label() + Me.Label22 = New System.Windows.Forms.Label() Me.Label24 = New System.Windows.Forms.Label() Me.Label25 = New System.Windows.Forms.Label() - Me.btnAddPos = New VERAG_PROG_ALLGEMEIN.FlatButton() - Me.btnAddSicherheit = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.lblGestellungNr = New System.Windows.Forms.Label() Me.txtPosTime = New System.Windows.Forms.TextBox() Me.txtPosDate = New System.Windows.Forms.TextBox() @@ -72,7 +71,6 @@ Partial Class frmGesamtsicherheitenNEU Me.txtSicherheitSicherheitsbetrag = New System.Windows.Forms.TextBox() Me.txtSicherheitWarenwert = New System.Windows.Forms.TextBox() Me.txtSicherheitATBNr = New System.Windows.Forms.TextBox() - Me.btn_resetSearch = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.lblZollsatz = New System.Windows.Forms.Label() Me.lblReferenzwert = New System.Windows.Forms.Label() Me.lblSaldo = New System.Windows.Forms.Label() @@ -89,11 +87,11 @@ Partial Class frmGesamtsicherheitenNEU Me.Panel1 = New System.Windows.Forms.Panel() Me.cbx_offene = New System.Windows.Forms.CheckBox() Me.btnSuche = New System.Windows.Forms.Button() - Me.Label23 = New System.Windows.Forms.Label() Me.cbx_Suche_Warenort = New VERAG_PROG_ALLGEMEIN.MyComboBox() Me.Label19 = New System.Windows.Forms.Label() Me.txt_Suche = New System.Windows.Forms.TextBox() Me.Label21 = New System.Windows.Forms.Label() + Me.btn_resetSearch = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.btnDeletePos = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.btnDeleteSicherheit = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.btnUpdatePos = New VERAG_PROG_ALLGEMEIN.FlatButton() @@ -118,56 +116,18 @@ Partial Class frmGesamtsicherheitenNEU Me.Label1 = New System.Windows.Forms.Label() Me.txtPosFreitext = New System.Windows.Forms.TextBox() Me.txtSicherheitFreitext = New System.Windows.Forms.TextBox() - CType(Me.dgvGesamtsicherheit, System.ComponentModel.ISupportInitialize).BeginInit() + Me.btnAddPos = New VERAG_PROG_ALLGEMEIN.FlatButton() + Me.btnAddSicherheit = New VERAG_PROG_ALLGEMEIN.FlatButton() Me.ContextMenuStrip1.SuspendLayout() Me.Panel2.SuspendLayout() - Me.pnlSummeGesPos.SuspendLayout() Me.panOverlay.SuspendLayout() + CType(Me.dgvGesamtsicherheit, System.ComponentModel.ISupportInitialize).BeginInit() CType(Me.dgvSicherheitsPos, System.ComponentModel.ISupportInitialize).BeginInit() Me.pnlSummeGes.SuspendLayout() Me.panOben.SuspendLayout() Me.Panel1.SuspendLayout() Me.SuspendLayout() ' - 'dgvGesamtsicherheit - ' - Me.dgvGesamtsicherheit.AKTUALISIERUNGS_INTERVALL = -1 - Me.dgvGesamtsicherheit.AllowUserToAddRows = False - Me.dgvGesamtsicherheit.AllowUserToDeleteRows = False - DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle1.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvGesamtsicherheit.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle1 - Me.dgvGesamtsicherheit.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize - Me.dgvGesamtsicherheit.ContextMenuStrip = Me.ContextMenuStrip1 - DataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window - DataGridViewCellStyle2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText - DataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] - Me.dgvGesamtsicherheit.DefaultCellStyle = DataGridViewCellStyle2 - Me.dgvGesamtsicherheit.Dock = System.Windows.Forms.DockStyle.Left - Me.dgvGesamtsicherheit.Location = New System.Drawing.Point(0, 0) - Me.dgvGesamtsicherheit.Name = "dgvGesamtsicherheit" - Me.dgvGesamtsicherheit.ReadOnly = True - DataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft - DataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Control - DataGridViewCellStyle3.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - DataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.WindowText - DataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight - DataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText - DataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] - Me.dgvGesamtsicherheit.RowHeadersDefaultCellStyle = DataGridViewCellStyle3 - Me.dgvGesamtsicherheit.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect - Me.dgvGesamtsicherheit.Size = New System.Drawing.Size(742, 486) - Me.dgvGesamtsicherheit.TabIndex = 0 - ' 'ContextMenuStrip1 ' Me.ContextMenuStrip1.Items.AddRange(New System.Windows.Forms.ToolStripItem() {Me.ClosedErzeugenToolStripMenuItem}) @@ -182,120 +142,21 @@ Partial Class frmGesamtsicherheitenNEU ' 'Panel2 ' - Me.Panel2.Controls.Add(Me.pnlSummeGesPos) Me.Panel2.Controls.Add(Me.panOverlay) + Me.Panel2.Controls.Add(Me.dgvGesamtsicherheit) Me.Panel2.Controls.Add(Me.dgvSicherheitsPos) Me.Panel2.Controls.Add(Me.pnlSummeGes) - Me.Panel2.Controls.Add(Me.dgvGesamtsicherheit) Me.Panel2.Dock = System.Windows.Forms.DockStyle.Fill Me.Panel2.Location = New System.Drawing.Point(0, 290) Me.Panel2.Name = "Panel2" Me.Panel2.Size = New System.Drawing.Size(1384, 486) Me.Panel2.TabIndex = 1 ' - 'pnlSummeGesPos - ' - Me.pnlSummeGesPos.BackColor = System.Drawing.SystemColors.ButtonHighlight - Me.pnlSummeGesPos.Controls.Add(Me.txtPosSicherheitsbGes) - Me.pnlSummeGesPos.Controls.Add(Me.txtPosWarenwertGes) - Me.pnlSummeGesPos.Controls.Add(Me.txtPosAnzalPosGes) - Me.pnlSummeGesPos.Controls.Add(Me.Label29) - Me.pnlSummeGesPos.Controls.Add(Me.Label28) - Me.pnlSummeGesPos.Controls.Add(Me.Label22) - Me.pnlSummeGesPos.Location = New System.Drawing.Point(748, 451) - Me.pnlSummeGesPos.Name = "pnlSummeGesPos" - Me.pnlSummeGesPos.Size = New System.Drawing.Size(636, 35) - Me.pnlSummeGesPos.TabIndex = 4 - ' - 'txtPosSicherheitsbGes - ' - Me.txtPosSicherheitsbGes._DateTimeOnly = False - Me.txtPosSicherheitsbGes._numbersOnly = False - Me.txtPosSicherheitsbGes._numbersOnlyKommastellen = "" - Me.txtPosSicherheitsbGes._numbersOnlyTrennzeichen = False - Me.txtPosSicherheitsbGes._Prozent = False - Me.txtPosSicherheitsbGes._ShortDateNew = False - Me.txtPosSicherheitsbGes._ShortDateOnly = False - Me.txtPosSicherheitsbGes._TimeOnly = False - Me.txtPosSicherheitsbGes._TimeOnly_Seconds = False - Me.txtPosSicherheitsbGes._value = "" - Me.txtPosSicherheitsbGes._Waehrung = True - Me.txtPosSicherheitsbGes._WaehrungZeichen = True - Me.txtPosSicherheitsbGes.ForeColor = System.Drawing.Color.Black - Me.txtPosSicherheitsbGes.Location = New System.Drawing.Point(533, 10) - Me.txtPosSicherheitsbGes.MaxLineLength = -1 - Me.txtPosSicherheitsbGes.MaxLines_Warning = "" - Me.txtPosSicherheitsbGes.MaxLines_Warning_Label = Nothing - Me.txtPosSicherheitsbGes.Name = "txtPosSicherheitsbGes" - Me.txtPosSicherheitsbGes.ReadOnly = True - Me.txtPosSicherheitsbGes.Size = New System.Drawing.Size(100, 20) - Me.txtPosSicherheitsbGes.TabIndex = 5 - ' - 'txtPosWarenwertGes - ' - Me.txtPosWarenwertGes._DateTimeOnly = False - Me.txtPosWarenwertGes._numbersOnly = False - Me.txtPosWarenwertGes._numbersOnlyKommastellen = "" - Me.txtPosWarenwertGes._numbersOnlyTrennzeichen = False - Me.txtPosWarenwertGes._Prozent = False - Me.txtPosWarenwertGes._ShortDateNew = False - Me.txtPosWarenwertGes._ShortDateOnly = False - Me.txtPosWarenwertGes._TimeOnly = False - Me.txtPosWarenwertGes._TimeOnly_Seconds = False - Me.txtPosWarenwertGes._value = "" - Me.txtPosWarenwertGes._Waehrung = True - Me.txtPosWarenwertGes._WaehrungZeichen = True - Me.txtPosWarenwertGes.ForeColor = System.Drawing.Color.Black - Me.txtPosWarenwertGes.Location = New System.Drawing.Point(261, 10) - Me.txtPosWarenwertGes.MaxLineLength = -1 - Me.txtPosWarenwertGes.MaxLines_Warning = "" - Me.txtPosWarenwertGes.MaxLines_Warning_Label = Nothing - Me.txtPosWarenwertGes.Name = "txtPosWarenwertGes" - Me.txtPosWarenwertGes.ReadOnly = True - Me.txtPosWarenwertGes.Size = New System.Drawing.Size(100, 20) - Me.txtPosWarenwertGes.TabIndex = 3 - ' - 'txtPosAnzalPosGes - ' - Me.txtPosAnzalPosGes.Location = New System.Drawing.Point(84, 10) - Me.txtPosAnzalPosGes.Name = "txtPosAnzalPosGes" - Me.txtPosAnzalPosGes.ReadOnly = True - Me.txtPosAnzalPosGes.Size = New System.Drawing.Size(53, 20) - Me.txtPosAnzalPosGes.TabIndex = 1 - ' - 'Label29 - ' - Me.Label29.AutoSize = True - Me.Label29.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label29.Location = New System.Drawing.Point(155, 13) - Me.Label29.Name = "Label29" - Me.Label29.Size = New System.Drawing.Size(103, 13) - Me.Label29.TabIndex = 2 - Me.Label29.Text = "Warentwert Summe:" - ' - 'Label28 - ' - Me.Label28.AutoSize = True - Me.Label28.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label28.Location = New System.Drawing.Point(397, 13) - Me.Label28.Name = "Label28" - Me.Label28.Size = New System.Drawing.Size(130, 13) - Me.Label28.TabIndex = 4 - Me.Label28.Text = "Sicherheitsbetrag Summe:" - ' - 'Label22 - ' - Me.Label22.AutoSize = True - Me.Label22.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label22.Location = New System.Drawing.Point(3, 13) - Me.Label22.Name = "Label22" - Me.Label22.Size = New System.Drawing.Size(63, 13) - Me.Label22.TabIndex = 0 - Me.Label22.Text = "Anzahl Pos:" - ' 'panOverlay ' Me.panOverlay.BackColor = System.Drawing.SystemColors.ButtonHighlight + Me.panOverlay.Controls.Add(Me.txtlkwIdSearch) + Me.panOverlay.Controls.Add(Me.Label23) Me.panOverlay.Controls.Add(Me.cboWarenort) Me.panOverlay.Controls.Add(Me.lblWarenort) Me.panOverlay.Controls.Add(Me.cboFiliale) @@ -308,10 +169,45 @@ Partial Class frmGesamtsicherheitenNEU Me.panOverlay.Controls.Add(Me.btnClosePanOverlay) Me.panOverlay.Location = New System.Drawing.Point(493, 15) Me.panOverlay.Name = "panOverlay" - Me.panOverlay.Size = New System.Drawing.Size(527, 275) + Me.panOverlay.Size = New System.Drawing.Size(527, 297) Me.panOverlay.TabIndex = 2 Me.panOverlay.Visible = False ' + 'txtlkwIdSearch + ' + Me.txtlkwIdSearch._allowFreitext = False + Me.txtlkwIdSearch._AllowSetValue = False + Me.txtlkwIdSearch._allowSpaceAsSplitter = False + Me.txtlkwIdSearch._autoSizeGross = False + Me.txtlkwIdSearch._hideIfListEmpty = True + Me.txtlkwIdSearch._value = Nothing + Me.txtlkwIdSearch.conn_art = "FMZOLL" + Me.txtlkwIdSearch.dgvpos = "LEFT" + Me.txtlkwIdSearch.DISPLAY_PARAM = Nothing + Me.txtlkwIdSearch.INVISIBLE_COLUMNS = Nothing + Me.txtlkwIdSearch.key_visible = False + Me.txtlkwIdSearch.KEYPARAM = Nothing + Me.txtlkwIdSearch.Location = New System.Drawing.Point(279, 184) + Me.txtlkwIdSearch.Name = "txtlkwIdSearch" + Me.txtlkwIdSearch.searchActive = True + Me.txtlkwIdSearch.Size = New System.Drawing.Size(186, 20) + Me.txtlkwIdSearch.SQL_ORDER_BY = Nothing + Me.txtlkwIdSearch.SQL_SELECT = Nothing + Me.txtlkwIdSearch.SQL_WHERE = Nothing + Me.txtlkwIdSearch.SQL_WhereParamList = Nothing + Me.txtlkwIdSearch.TabIndex = 11 + Me.txtlkwIdSearch.usrcntl = Nothing + ' + 'Label23 + ' + Me.Label23.AutoSize = True + Me.Label23.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + Me.Label23.Location = New System.Drawing.Point(176, 184) + Me.Label23.Name = "Label23" + Me.Label23.Size = New System.Drawing.Size(73, 20) + Me.Label23.TabIndex = 10 + Me.Label23.Text = "LKW-Id:" + ' 'cboWarenort ' Me.cboWarenort._allowedValuesFreiText = Nothing @@ -330,7 +226,7 @@ Partial Class frmGesamtsicherheitenNEU ' Me.lblWarenort.AutoSize = True Me.lblWarenort.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.lblWarenort.Location = New System.Drawing.Point(125, 68) + Me.lblWarenort.Location = New System.Drawing.Point(161, 64) Me.lblWarenort.Name = "lblWarenort" Me.lblWarenort.Size = New System.Drawing.Size(88, 20) Me.lblWarenort.TabIndex = 1 @@ -357,7 +253,7 @@ Partial Class frmGesamtsicherheitenNEU Me.btnSave.FlatAppearance.BorderSize = 0 Me.btnSave.FlatStyle = System.Windows.Forms.FlatStyle.Flat Me.btnSave.ForeColor = System.Drawing.Color.Black - Me.btnSave.Location = New System.Drawing.Point(424, 232) + Me.btnSave.Location = New System.Drawing.Point(389, 252) Me.btnSave.Name = "btnSave" Me.btnSave.Size = New System.Drawing.Size(75, 23) Me.btnSave.TabIndex = 9 @@ -367,7 +263,7 @@ Partial Class frmGesamtsicherheitenNEU 'txtLKWID ' Me.txtLKWID.Font = New System.Drawing.Font("Microsoft Sans Serif", 11.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.txtLKWID.Location = New System.Drawing.Point(279, 178) + Me.txtLKWID.Location = New System.Drawing.Point(279, 216) Me.txtLKWID.Margin = New System.Windows.Forms.Padding(0) Me.txtLKWID.Name = "txtLKWID" Me.txtLKWID.Size = New System.Drawing.Size(186, 24) @@ -386,11 +282,11 @@ Partial Class frmGesamtsicherheitenNEU ' Me.Label18.AutoSize = True Me.Label18.Font = New System.Drawing.Font("Microsoft Sans Serif", 12.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label18.Location = New System.Drawing.Point(173, 180) + Me.Label18.Location = New System.Drawing.Point(89, 218) Me.Label18.Name = "Label18" - Me.Label18.Size = New System.Drawing.Size(76, 20) + Me.Label18.Size = New System.Drawing.Size(160, 20) Me.Label18.TabIndex = 7 - Me.Label18.Text = "LKW-ID:" + Me.Label18.Text = "LKW-Kennzeichen:" ' 'Label17 ' @@ -428,6 +324,45 @@ Partial Class frmGesamtsicherheitenNEU Me.btnClosePanOverlay.TabIndex = 0 Me.btnClosePanOverlay.UseVisualStyleBackColor = False ' + 'dgvGesamtsicherheit + ' + Me.dgvGesamtsicherheit.AKTUALISIERUNGS_INTERVALL = -1 + Me.dgvGesamtsicherheit.AllowUserToAddRows = False + Me.dgvGesamtsicherheit.AllowUserToDeleteRows = False + DataGridViewCellStyle1.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle1.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle1.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle1.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle1.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle1.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle1.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvGesamtsicherheit.ColumnHeadersDefaultCellStyle = DataGridViewCellStyle1 + Me.dgvGesamtsicherheit.ColumnHeadersHeightSizeMode = System.Windows.Forms.DataGridViewColumnHeadersHeightSizeMode.AutoSize + Me.dgvGesamtsicherheit.ContextMenuStrip = Me.ContextMenuStrip1 + DataGridViewCellStyle2.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle2.BackColor = System.Drawing.SystemColors.Window + DataGridViewCellStyle2.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle2.ForeColor = System.Drawing.SystemColors.ControlText + DataGridViewCellStyle2.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle2.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle2.WrapMode = System.Windows.Forms.DataGridViewTriState.[False] + Me.dgvGesamtsicherheit.DefaultCellStyle = DataGridViewCellStyle2 + Me.dgvGesamtsicherheit.Dock = System.Windows.Forms.DockStyle.Left + Me.dgvGesamtsicherheit.Location = New System.Drawing.Point(0, 0) + Me.dgvGesamtsicherheit.Name = "dgvGesamtsicherheit" + Me.dgvGesamtsicherheit.ReadOnly = True + DataGridViewCellStyle3.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleLeft + DataGridViewCellStyle3.BackColor = System.Drawing.SystemColors.Control + DataGridViewCellStyle3.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.25!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + DataGridViewCellStyle3.ForeColor = System.Drawing.SystemColors.WindowText + DataGridViewCellStyle3.SelectionBackColor = System.Drawing.SystemColors.Highlight + DataGridViewCellStyle3.SelectionForeColor = System.Drawing.SystemColors.HighlightText + DataGridViewCellStyle3.WrapMode = System.Windows.Forms.DataGridViewTriState.[True] + Me.dgvGesamtsicherheit.RowHeadersDefaultCellStyle = DataGridViewCellStyle3 + Me.dgvGesamtsicherheit.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect + Me.dgvGesamtsicherheit.Size = New System.Drawing.Size(742, 454) + Me.dgvGesamtsicherheit.TabIndex = 0 + ' 'dgvSicherheitsPos ' Me.dgvSicherheitsPos.AKTUALISIERUNGS_INTERVALL = -1 @@ -455,23 +390,54 @@ Partial Class frmGesamtsicherheitenNEU Me.dgvSicherheitsPos.Name = "dgvSicherheitsPos" Me.dgvSicherheitsPos.ReadOnly = True Me.dgvSicherheitsPos.SelectionMode = System.Windows.Forms.DataGridViewSelectionMode.FullRowSelect - Me.dgvSicherheitsPos.Size = New System.Drawing.Size(636, 486) + Me.dgvSicherheitsPos.Size = New System.Drawing.Size(636, 454) Me.dgvSicherheitsPos.TabIndex = 1 ' 'pnlSummeGes ' Me.pnlSummeGes.BackColor = System.Drawing.SystemColors.ButtonHighlight + Me.pnlSummeGes.Controls.Add(Me.txtPosSicherheitsbGes) Me.pnlSummeGes.Controls.Add(Me.txtSicherheitsbGes) + Me.pnlSummeGes.Controls.Add(Me.Label28) + Me.pnlSummeGes.Controls.Add(Me.txtPosWarenwertGes) + Me.pnlSummeGes.Controls.Add(Me.Label29) Me.pnlSummeGes.Controls.Add(Me.txtWarenwertGes) + Me.pnlSummeGes.Controls.Add(Me.txtPosAnzalPosGes) Me.pnlSummeGes.Controls.Add(Me.txtAnzalPosGes) Me.pnlSummeGes.Controls.Add(Me.Label27) + Me.pnlSummeGes.Controls.Add(Me.Label22) Me.pnlSummeGes.Controls.Add(Me.Label24) Me.pnlSummeGes.Controls.Add(Me.Label25) - Me.pnlSummeGes.Location = New System.Drawing.Point(0, 451) + Me.pnlSummeGes.Dock = System.Windows.Forms.DockStyle.Bottom + Me.pnlSummeGes.Location = New System.Drawing.Point(0, 454) Me.pnlSummeGes.Name = "pnlSummeGes" - Me.pnlSummeGes.Size = New System.Drawing.Size(742, 35) + Me.pnlSummeGes.Size = New System.Drawing.Size(1384, 32) Me.pnlSummeGes.TabIndex = 3 ' + 'txtPosSicherheitsbGes + ' + Me.txtPosSicherheitsbGes._DateTimeOnly = False + Me.txtPosSicherheitsbGes._numbersOnly = False + Me.txtPosSicherheitsbGes._numbersOnlyKommastellen = "" + Me.txtPosSicherheitsbGes._numbersOnlyTrennzeichen = False + Me.txtPosSicherheitsbGes._Prozent = False + Me.txtPosSicherheitsbGes._ShortDateNew = False + Me.txtPosSicherheitsbGes._ShortDateOnly = False + Me.txtPosSicherheitsbGes._TimeOnly = False + Me.txtPosSicherheitsbGes._TimeOnly_Seconds = False + Me.txtPosSicherheitsbGes._value = "" + Me.txtPosSicherheitsbGes._Waehrung = True + Me.txtPosSicherheitsbGes._WaehrungZeichen = True + Me.txtPosSicherheitsbGes.ForeColor = System.Drawing.Color.Black + Me.txtPosSicherheitsbGes.Location = New System.Drawing.Point(1272, 6) + Me.txtPosSicherheitsbGes.MaxLineLength = -1 + Me.txtPosSicherheitsbGes.MaxLines_Warning = "" + Me.txtPosSicherheitsbGes.MaxLines_Warning_Label = Nothing + Me.txtPosSicherheitsbGes.Name = "txtPosSicherheitsbGes" + Me.txtPosSicherheitsbGes.ReadOnly = True + Me.txtPosSicherheitsbGes.Size = New System.Drawing.Size(100, 20) + Me.txtPosSicherheitsbGes.TabIndex = 5 + ' 'txtSicherheitsbGes ' Me.txtSicherheitsbGes._DateTimeOnly = False @@ -487,7 +453,7 @@ Partial Class frmGesamtsicherheitenNEU Me.txtSicherheitsbGes._Waehrung = True Me.txtSicherheitsbGes._WaehrungZeichen = True Me.txtSicherheitsbGes.ForeColor = System.Drawing.Color.Black - Me.txtSicherheitsbGes.Location = New System.Drawing.Point(638, 10) + Me.txtSicherheitsbGes.Location = New System.Drawing.Point(615, 5) Me.txtSicherheitsbGes.MaxLineLength = -1 Me.txtSicherheitsbGes.MaxLines_Warning = "" Me.txtSicherheitsbGes.MaxLines_Warning_Label = Nothing @@ -496,6 +462,50 @@ Partial Class frmGesamtsicherheitenNEU Me.txtSicherheitsbGes.Size = New System.Drawing.Size(100, 20) Me.txtSicherheitsbGes.TabIndex = 5 ' + 'Label28 + ' + Me.Label28.AutoSize = True + Me.Label28.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + Me.Label28.Location = New System.Drawing.Point(1128, 9) + Me.Label28.Name = "Label28" + Me.Label28.Size = New System.Drawing.Size(130, 13) + Me.Label28.TabIndex = 4 + Me.Label28.Text = "Sicherheitsbetrag Summe:" + ' + 'txtPosWarenwertGes + ' + Me.txtPosWarenwertGes._DateTimeOnly = False + Me.txtPosWarenwertGes._numbersOnly = False + Me.txtPosWarenwertGes._numbersOnlyKommastellen = "" + Me.txtPosWarenwertGes._numbersOnlyTrennzeichen = False + Me.txtPosWarenwertGes._Prozent = False + Me.txtPosWarenwertGes._ShortDateNew = False + Me.txtPosWarenwertGes._ShortDateOnly = False + Me.txtPosWarenwertGes._TimeOnly = False + Me.txtPosWarenwertGes._TimeOnly_Seconds = False + Me.txtPosWarenwertGes._value = "" + Me.txtPosWarenwertGes._Waehrung = True + Me.txtPosWarenwertGes._WaehrungZeichen = True + Me.txtPosWarenwertGes.ForeColor = System.Drawing.Color.Black + Me.txtPosWarenwertGes.Location = New System.Drawing.Point(1018, 6) + Me.txtPosWarenwertGes.MaxLineLength = -1 + Me.txtPosWarenwertGes.MaxLines_Warning = "" + Me.txtPosWarenwertGes.MaxLines_Warning_Label = Nothing + Me.txtPosWarenwertGes.Name = "txtPosWarenwertGes" + Me.txtPosWarenwertGes.ReadOnly = True + Me.txtPosWarenwertGes.Size = New System.Drawing.Size(100, 20) + Me.txtPosWarenwertGes.TabIndex = 3 + ' + 'Label29 + ' + Me.Label29.AutoSize = True + Me.Label29.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + Me.Label29.Location = New System.Drawing.Point(909, 9) + Me.Label29.Name = "Label29" + Me.Label29.Size = New System.Drawing.Size(103, 13) + Me.Label29.TabIndex = 2 + Me.Label29.Text = "Warentwert Summe:" + ' 'txtWarenwertGes ' Me.txtWarenwertGes._DateTimeOnly = False @@ -511,7 +521,7 @@ Partial Class frmGesamtsicherheitenNEU Me.txtWarenwertGes._Waehrung = True Me.txtWarenwertGes._WaehrungZeichen = True Me.txtWarenwertGes.ForeColor = System.Drawing.Color.Black - Me.txtWarenwertGes.Location = New System.Drawing.Point(315, 10) + Me.txtWarenwertGes.Location = New System.Drawing.Point(326, 6) Me.txtWarenwertGes.MaxLineLength = -1 Me.txtWarenwertGes.MaxLines_Warning = "" Me.txtWarenwertGes.MaxLines_Warning_Label = Nothing @@ -520,9 +530,17 @@ Partial Class frmGesamtsicherheitenNEU Me.txtWarenwertGes.Size = New System.Drawing.Size(100, 20) Me.txtWarenwertGes.TabIndex = 3 ' + 'txtPosAnzalPosGes + ' + Me.txtPosAnzalPosGes.Location = New System.Drawing.Point(830, 6) + Me.txtPosAnzalPosGes.Name = "txtPosAnzalPosGes" + Me.txtPosAnzalPosGes.ReadOnly = True + Me.txtPosAnzalPosGes.Size = New System.Drawing.Size(53, 20) + Me.txtPosAnzalPosGes.TabIndex = 1 + ' 'txtAnzalPosGes ' - Me.txtAnzalPosGes.Location = New System.Drawing.Point(89, 10) + Me.txtAnzalPosGes.Location = New System.Drawing.Point(93, 5) Me.txtAnzalPosGes.Name = "txtAnzalPosGes" Me.txtAnzalPosGes.ReadOnly = True Me.txtAnzalPosGes.Size = New System.Drawing.Size(53, 20) @@ -532,17 +550,27 @@ Partial Class frmGesamtsicherheitenNEU ' Me.Label27.AutoSize = True Me.Label27.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label27.Location = New System.Drawing.Point(479, 13) + Me.Label27.Location = New System.Drawing.Point(479, 9) Me.Label27.Name = "Label27" Me.Label27.Size = New System.Drawing.Size(130, 13) Me.Label27.TabIndex = 4 Me.Label27.Text = "Sicherheitsbetrag Summe:" ' + 'Label22 + ' + Me.Label22.AutoSize = True + Me.Label22.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) + Me.Label22.Location = New System.Drawing.Point(759, 9) + Me.Label22.Name = "Label22" + Me.Label22.Size = New System.Drawing.Size(63, 13) + Me.Label22.TabIndex = 0 + Me.Label22.Text = "Anzahl Pos:" + ' 'Label24 ' Me.Label24.AutoSize = True Me.Label24.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label24.Location = New System.Drawing.Point(9, 13) + Me.Label24.Location = New System.Drawing.Point(9, 8) Me.Label24.Name = "Label24" Me.Label24.Size = New System.Drawing.Size(63, 13) Me.Label24.TabIndex = 0 @@ -552,42 +580,12 @@ Partial Class frmGesamtsicherheitenNEU ' Me.Label25.AutoSize = True Me.Label25.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label25.Location = New System.Drawing.Point(194, 13) + Me.Label25.Location = New System.Drawing.Point(194, 8) Me.Label25.Name = "Label25" Me.Label25.Size = New System.Drawing.Size(103, 13) Me.Label25.TabIndex = 2 Me.Label25.Text = "Warentwert Summe:" ' - 'btnAddPos - ' - Me.btnAddPos.allowBorder = False - Me.btnAddPos.BackColor = System.Drawing.Color.White - Me.btnAddPos.BackgroundImage = Global.AVISO.My.Resources.Resources.plus - Me.btnAddPos.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch - Me.btnAddPos.FlatAppearance.BorderSize = 0 - Me.btnAddPos.FlatStyle = System.Windows.Forms.FlatStyle.Flat - Me.btnAddPos.ForeColor = System.Drawing.Color.Black - Me.btnAddPos.Location = New System.Drawing.Point(1348, 225) - Me.btnAddPos.Name = "btnAddPos" - Me.btnAddPos.Size = New System.Drawing.Size(24, 24) - Me.btnAddPos.TabIndex = 38 - Me.btnAddPos.UseVisualStyleBackColor = False - ' - 'btnAddSicherheit - ' - Me.btnAddSicherheit.allowBorder = False - Me.btnAddSicherheit.BackColor = System.Drawing.Color.White - Me.btnAddSicherheit.BackgroundImage = Global.AVISO.My.Resources.Resources.plus - Me.btnAddSicherheit.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch - Me.btnAddSicherheit.FlatAppearance.BorderSize = 0 - Me.btnAddSicherheit.FlatStyle = System.Windows.Forms.FlatStyle.Flat - Me.btnAddSicherheit.ForeColor = System.Drawing.Color.Black - Me.btnAddSicherheit.Location = New System.Drawing.Point(663, 205) - Me.btnAddSicherheit.Name = "btnAddSicherheit" - Me.btnAddSicherheit.Size = New System.Drawing.Size(24, 24) - Me.btnAddSicherheit.TabIndex = 36 - Me.btnAddSicherheit.UseVisualStyleBackColor = False - ' 'lblGestellungNr ' Me.lblGestellungNr.Anchor = System.Windows.Forms.AnchorStyles.Right @@ -696,20 +694,6 @@ Partial Class frmGesamtsicherheitenNEU Me.txtSicherheitATBNr.Size = New System.Drawing.Size(205, 24) Me.txtSicherheitATBNr.TabIndex = 25 ' - 'btn_resetSearch - ' - Me.btn_resetSearch.allowBorder = False - Me.btn_resetSearch.BackColor = System.Drawing.Color.White - Me.btn_resetSearch.FlatAppearance.BorderSize = 0 - Me.btn_resetSearch.FlatStyle = System.Windows.Forms.FlatStyle.Flat - Me.btn_resetSearch.ForeColor = System.Drawing.Color.Black - Me.btn_resetSearch.Image = Global.AVISO.My.Resources.Resources.refresh - Me.btn_resetSearch.Location = New System.Drawing.Point(813, 8) - Me.btn_resetSearch.Name = "btn_resetSearch" - Me.btn_resetSearch.Size = New System.Drawing.Size(32, 33) - Me.btn_resetSearch.TabIndex = 4 - Me.btn_resetSearch.UseVisualStyleBackColor = False - ' 'lblZollsatz ' Me.lblZollsatz.Anchor = System.Windows.Forms.AnchorStyles.Right @@ -888,9 +872,9 @@ Partial Class frmGesamtsicherheitenNEU Me.lbloffenerSaldo.ForeColor = System.Drawing.Color.Red Me.lbloffenerSaldo.Location = New System.Drawing.Point(238, 108) Me.lbloffenerSaldo.Name = "lbloffenerSaldo" - Me.lbloffenerSaldo.Size = New System.Drawing.Size(146, 24) + Me.lbloffenerSaldo.Size = New System.Drawing.Size(190, 24) Me.lbloffenerSaldo.TabIndex = 4 - Me.lbloffenerSaldo.Text = "offener Saldo: " + Me.lbloffenerSaldo.Text = "offener S-Betrag: €" ' 'btnPrev ' @@ -930,13 +914,12 @@ Partial Class frmGesamtsicherheitenNEU Me.Panel1.BackColor = System.Drawing.SystemColors.ButtonHighlight Me.Panel1.Controls.Add(Me.cbx_offene) Me.Panel1.Controls.Add(Me.btnSuche) - Me.Panel1.Controls.Add(Me.Label23) Me.Panel1.Controls.Add(Me.cbx_Suche_Warenort) Me.Panel1.Controls.Add(Me.Label19) Me.Panel1.Controls.Add(Me.txt_Suche) Me.Panel1.Controls.Add(Me.Label21) Me.Panel1.Controls.Add(Me.btn_resetSearch) - Me.Panel1.Location = New System.Drawing.Point(0, 44) + Me.Panel1.Location = New System.Drawing.Point(3, 41) Me.Panel1.Name = "Panel1" Me.Panel1.Size = New System.Drawing.Size(1384, 61) Me.Panel1.TabIndex = 2 @@ -956,25 +939,13 @@ Partial Class frmGesamtsicherheitenNEU 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.ImageAlign = System.Drawing.ContentAlignment.MiddleLeft - Me.btnSuche.Location = New System.Drawing.Point(893, 3) + Me.btnSuche.Location = New System.Drawing.Point(737, 3) Me.btnSuche.Name = "btnSuche" Me.btnSuche.Size = New System.Drawing.Size(162, 52) Me.btnSuche.TabIndex = 7 Me.btnSuche.Text = "Suche starten" Me.btnSuche.UseVisualStyleBackColor = True ' - 'Label23 - ' - Me.Label23.Anchor = System.Windows.Forms.AnchorStyles.Right - Me.Label23.AutoSize = True - Me.Label23.Font = New System.Drawing.Font("Microsoft Sans Serif", 9.0!) - Me.Label23.ForeColor = System.Drawing.Color.Honeydew - Me.Label23.Location = New System.Drawing.Point(207, -13) - Me.Label23.Name = "Label23" - Me.Label23.Size = New System.Drawing.Size(24, 15) - Me.Label23.TabIndex = 0 - Me.Label23.Text = "Bis" - ' 'cbx_Suche_Warenort ' Me.cbx_Suche_Warenort._allowedValuesFreiText = Nothing @@ -983,21 +954,23 @@ Partial Class frmGesamtsicherheitenNEU Me.cbx_Suche_Warenort.DropDownWidth = 300 Me.cbx_Suche_Warenort.Font = New System.Drawing.Font("Microsoft Sans Serif", 10.0!, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) Me.cbx_Suche_Warenort.FormattingEnabled = True - Me.cbx_Suche_Warenort.Location = New System.Drawing.Point(660, 20) + Me.cbx_Suche_Warenort.Location = New System.Drawing.Point(274, 20) Me.cbx_Suche_Warenort.MaxLength = 4 Me.cbx_Suche_Warenort.Name = "cbx_Suche_Warenort" Me.cbx_Suche_Warenort.Size = New System.Drawing.Size(95, 24) Me.cbx_Suche_Warenort.TabIndex = 6 + Me.cbx_Suche_Warenort.Visible = False ' 'Label19 ' Me.Label19.AutoSize = True Me.Label19.Font = New System.Drawing.Font("Microsoft Sans Serif", 8.0!, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, CType(0, Byte)) - Me.Label19.Location = New System.Drawing.Point(657, 3) + Me.Label19.Location = New System.Drawing.Point(271, 3) Me.Label19.Name = "Label19" Me.Label19.Size = New System.Drawing.Size(63, 13) Me.Label19.TabIndex = 2 Me.Label19.Text = "Warenort:" + Me.Label19.Visible = False ' 'txt_Suche ' @@ -1018,6 +991,20 @@ Partial Class frmGesamtsicherheitenNEU Me.Label21.TabIndex = 1 Me.Label21.Text = "Suche:" ' + 'btn_resetSearch + ' + Me.btn_resetSearch.allowBorder = False + Me.btn_resetSearch.BackColor = System.Drawing.Color.White + Me.btn_resetSearch.FlatAppearance.BorderSize = 0 + Me.btn_resetSearch.FlatStyle = System.Windows.Forms.FlatStyle.Flat + Me.btn_resetSearch.ForeColor = System.Drawing.Color.Black + Me.btn_resetSearch.Image = Global.AVISO.My.Resources.Resources.refresh + Me.btn_resetSearch.Location = New System.Drawing.Point(660, 10) + Me.btn_resetSearch.Name = "btn_resetSearch" + Me.btn_resetSearch.Size = New System.Drawing.Size(32, 33) + Me.btn_resetSearch.TabIndex = 4 + Me.btn_resetSearch.UseVisualStyleBackColor = False + ' 'btnDeletePos ' Me.btnDeletePos.allowBorder = False @@ -1282,6 +1269,36 @@ Partial Class frmGesamtsicherheitenNEU Me.txtSicherheitFreitext.Size = New System.Drawing.Size(256, 24) Me.txtSicherheitFreitext.TabIndex = 46 ' + 'btnAddPos + ' + Me.btnAddPos.allowBorder = False + Me.btnAddPos.BackColor = System.Drawing.Color.White + Me.btnAddPos.BackgroundImage = Global.AVISO.My.Resources.Resources.plus + Me.btnAddPos.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch + Me.btnAddPos.FlatAppearance.BorderSize = 0 + Me.btnAddPos.FlatStyle = System.Windows.Forms.FlatStyle.Flat + Me.btnAddPos.ForeColor = System.Drawing.Color.Black + Me.btnAddPos.Location = New System.Drawing.Point(1348, 225) + Me.btnAddPos.Name = "btnAddPos" + Me.btnAddPos.Size = New System.Drawing.Size(24, 24) + Me.btnAddPos.TabIndex = 38 + Me.btnAddPos.UseVisualStyleBackColor = False + ' + 'btnAddSicherheit + ' + Me.btnAddSicherheit.allowBorder = False + Me.btnAddSicherheit.BackColor = System.Drawing.Color.White + Me.btnAddSicherheit.BackgroundImage = Global.AVISO.My.Resources.Resources.plus + Me.btnAddSicherheit.BackgroundImageLayout = System.Windows.Forms.ImageLayout.Stretch + Me.btnAddSicherheit.FlatAppearance.BorderSize = 0 + Me.btnAddSicherheit.FlatStyle = System.Windows.Forms.FlatStyle.Flat + Me.btnAddSicherheit.ForeColor = System.Drawing.Color.Black + Me.btnAddSicherheit.Location = New System.Drawing.Point(663, 205) + Me.btnAddSicherheit.Name = "btnAddSicherheit" + Me.btnAddSicherheit.Size = New System.Drawing.Size(24, 24) + Me.btnAddSicherheit.TabIndex = 36 + Me.btnAddSicherheit.UseVisualStyleBackColor = False + ' 'frmGesamtsicherheitenNEU ' Me.AutoScaleDimensions = New System.Drawing.SizeF(6.0!, 13.0!) @@ -1295,13 +1312,11 @@ Partial Class frmGesamtsicherheitenNEU Me.Name = "frmGesamtsicherheitenNEU" Me.StartPosition = System.Windows.Forms.FormStartPosition.CenterScreen Me.Text = "frmGesSich" - CType(Me.dgvGesamtsicherheit, System.ComponentModel.ISupportInitialize).EndInit() Me.ContextMenuStrip1.ResumeLayout(False) Me.Panel2.ResumeLayout(False) - Me.pnlSummeGesPos.ResumeLayout(False) - Me.pnlSummeGesPos.PerformLayout() Me.panOverlay.ResumeLayout(False) Me.panOverlay.PerformLayout() + CType(Me.dgvGesamtsicherheit, System.ComponentModel.ISupportInitialize).EndInit() CType(Me.dgvSicherheitsPos, System.ComponentModel.ISupportInitialize).EndInit() Me.pnlSummeGes.ResumeLayout(False) Me.pnlSummeGes.PerformLayout() @@ -1376,7 +1391,6 @@ Partial Class frmGesamtsicherheitenNEU Friend WithEvents Label19 As Label Friend WithEvents txt_Suche As TextBox Friend WithEvents Label21 As Label - Friend WithEvents Label23 As Label Friend WithEvents btnSuche As Button Friend WithEvents Label20 As Label Friend WithEvents txtPosNr As TextBox @@ -1397,9 +1411,10 @@ Partial Class frmGesamtsicherheitenNEU Friend WithEvents Label24 As Label Friend WithEvents txtPosAnzalPosGes As TextBox Friend WithEvents txtAnzalPosGes As TextBox - Private WithEvents pnlSummeGesPos As Panel Friend WithEvents txtWarenwertGes As VERAG_PROG_ALLGEMEIN.MyTextBox Friend WithEvents txtSicherheitsbGes As VERAG_PROG_ALLGEMEIN.MyTextBox Friend WithEvents txtPosWarenwertGes As VERAG_PROG_ALLGEMEIN.MyTextBox Friend WithEvents txtPosSicherheitsbGes As VERAG_PROG_ALLGEMEIN.MyTextBox + Friend WithEvents Label23 As Label + Friend WithEvents txtlkwIdSearch As VERAG_PROG_ALLGEMEIN.MySearchBox End Class diff --git a/Aviso/frmGesamtsicherheitenNEU.vb b/Aviso/frmGesamtsicherheitenNEU.vb index 7da562f..1cd1c9b 100644 --- a/Aviso/frmGesamtsicherheitenNEU.vb +++ b/Aviso/frmGesamtsicherheitenNEU.vb @@ -1,21 +1,14 @@ -Imports System.Reflection -Imports System.Web.UI.WebControls -Imports System.Web.UI.WebControls.Expressions -Imports DocumentFormat.OpenXml.Bibliography -Imports DocumentFormat.OpenXml.Presentation -Imports DocumentFormat.OpenXml.Spreadsheet -Imports Spire.Pdf.General.Render.Decode + Imports VERAG_PROG_ALLGEMEIN Public Class frmGesamtsicherheitenNEU - Property currentSicherheit As cSicherheiten Property currentSPos As cGesamtsicherheitsPositionen Property currentGesSichRef As cGesamtsicherheitsReferenz Public Property gessicherheitID As Integer - Public Property prevGessicherheitID As Integer = 0 - Public Property nextGessicherheitID As Integer = 0 + Public Property prevGessicherheitID As Integer + Public Property nextGessicherheitID As Integer Public Property datum As DateTime = Nothing Property Standort As String = "" @@ -35,6 +28,8 @@ Public Class frmGesamtsicherheitenNEU Public warenortID As String + Public avisioID As Integer + Dim indexGsId As Integer Dim indexGspPosId As Integer @@ -43,7 +38,7 @@ Public Class frmGesamtsicherheitenNEU Dim SQL As New VERAG_PROG_ALLGEMEIN.SQL - Public dt As New DataTable + Public dataTable As New DataTable() Private Sub frmGesamtsicherheitNEU_Load(sender As Object, e As EventArgs) Handles MyBase.Load @@ -69,6 +64,8 @@ Public Class frmGesamtsicherheitenNEU nextGessicherheitID = -1 prevGessicherheitID = -1 + txtlkwIdSearch.initSearchBox(Me.FindForm, " LKW_Nr, AvisoID, CAST(Datum as Date) as Datum FROM [Aviso]", {"LKW_Nr", "AvisoID", "Datum"}, "", "Datum desc", "LKW_Nr", "AvisoID", "AVISO",, 250, 200) + Else LoadDGVSicherheiten() End If @@ -87,7 +84,7 @@ Public Class frmGesamtsicherheitenNEU Public Sub LoadDGVSicherheiten(Optional withFilterParam As Boolean = False) - lblSaldo.Text = "Saldo: € " & currentGesSichRef.gsr_Saldo.ToString() + 'lblSaldo.Text = "Saldo: € " & currentGesSichRef.gsr_Saldo.ToString() lblGestellungNr.Text = "" Dim sqladd1 As String = "" If currentGesSichRef.gsr_ustEnabled Then sqladd1 &= ", FORMAT((([gs_warenwert] + [gs_sicherheitsbetrag]) * " & currentGesSichRef.gsr_ust & "/100), 'C', 'de-DE') as gs_ust" @@ -98,9 +95,7 @@ Public Class frmGesamtsicherheitenNEU If cbx_Suche_Warenort._value <> "" Then sqlSearchSting &= "AND gs_warenort like '%" & cbx_Suche_Warenort._value & "%'" End If - 'Dim addtosqlstring As String = "" - - Dim SQLStringSicherheit As String = "select [gs_gsId], [gs_gsnr], [gs_posNr], [gs_ATBNr], [gs_datum], [gs_warenwert], [gs_sicherheitsbetrag], [gs_saldo] " & sqladd1 & " , [gs_freitext] from [tblGesamtsicherheit] where [gs_gsnr] = '" & gessicherheitID & "'" & sqlSearchSting & "order by [gs_gsId]" + Dim SQLStringSicherheit As String = "select [gs_gsId], [gs_gsnr], [gs_posNr], [gs_ATBNr], [gs_datum], [gs_warenwert], [gs_sicherheitsbetrag], [gs_saldo] " & sqladd1 & " , [gs_freitext] from [tblGesamtsicherheit] where [gs_gsnr] = '" & gessicherheitID & "'" & sqlSearchSting & "order by gs_gsId" dgvGesamtsicherheit.SET_SQL(SQLStringSicherheit, "AVISO", ,) dgvGesamtsicherheit.LOAD() @@ -160,7 +155,6 @@ Public Class frmGesamtsicherheitenNEU loadTitle() setSaldo() - If dgvGesamtsicherheit.Enabled = False Then Exit Sub Else @@ -245,12 +239,14 @@ Public Class frmGesamtsicherheitenNEU dt = SQL.loadDgvBySql(StandortSqlString, "AVISO", 100, True) If dt.Rows.Count > 0 Then + Me.avisioID = setNullToZero(dt.Rows(0).Item("gs_avisioId")) Me.LKWKZ = setNullToZero(dt.Rows(0).Item("gs_LKWKZ")) Me.FilialNummer = setNullToZero(dt.Rows(0).Item("gs_filialenNr")) Me.Abfertigungsnummer = setNullToZero(dt.Rows(0).Item("gs_abfertigungsNr")) Me.warenortID = setNullToZero(dt.Rows(0).Item("gs_warenort")) End If + If Me.avisioID.ToString.Length > 0 Then lblGestellungNr.Text &= "Aviso-ID: " & Me.LKWKZ & " " If Me.LKWKZ.ToString.Length > 0 Then lblGestellungNr.Text &= "LKW-ID: " & Me.LKWKZ & " " If Me.FilialNummer.ToString.Length > 0 Then lblGestellungNr.Text &= "FilialNr: " & Me.FilialNummer & " " If Me.Abfertigungsnummer.Length > 0 Then lblGestellungNr.Text &= "AbfNr: " & Me.Abfertigungsnummer & " " @@ -267,7 +263,7 @@ Public Class frmGesamtsicherheitenNEU Zollsatz = currentGesSichRef.gsr_zollsatz txtZollsatzueberschreiben.Text = Zollsatz cbxZollsatzueberschreiben.Checked = False - lblReferenzwert.Text = "Referenzwert: €" & currentGesSichRef.gsr_referenzwert.ToString() + lblReferenzwert.Text = "Referenzwert: € " & CDbl(currentGesSichRef.gsr_referenzwert).ToString("N") lblZollsatz.Text = "Zollsatz: " & currentGesSichRef.gsr_zollsatz & "%" ZollsatzMulti = currentGesSichRef.gsr_zollsatz / 100 @@ -364,12 +360,11 @@ Public Class frmGesamtsicherheitenNEU .gs_saldo = currentGesSichRef.gsr_Saldo .gs_atr = setNullToZero(cboSicherheitATR.SelectedItem) .gs_zollsatz = Me.Zollsatz + .gs_avisoId = Me.avisioID setEnviromentDataToObject(OPEN, Me) End With - - If Neu = True AndAlso count <= 1 Then OPEN.gs_gsNr = AddNewGesamtSichNr() Select Case checkIfExist(OPEN.gs_ATBNr, gessicherheitID) @@ -408,18 +403,15 @@ Public Class frmGesamtsicherheitenNEU .gsp_erstellungsdatum = Me.datum .gsp_avisoId = "" .gsp_ust = "" - .gsp_ATCNr = "" - .gsp_MRNNr = "" + .gsp_avisoId = Me.avisioID + '.gsp_ATCNr = "" + '.gsp_MRNNr = "" .gsp_gsNr = OPEN.gs_gsNr End With OPENPos.SAVE() - - - - Next AfterButton() @@ -457,6 +449,7 @@ Public Class frmGesamtsicherheitenNEU .gs_saldo = currentGesSichRef.gsr_Saldo .gs_atr = setNullToZero(cboSicherheitATR.SelectedItem) .gs_zollsatz = Me.Zollsatz + .gs_avisoId = Me.avisioID setEnviromentDataToObject(OPEN, Me) End With @@ -478,6 +471,7 @@ Public Class frmGesamtsicherheitenNEU .gsp_ust = currentSicherheit.gs_ust .gsp_ATCNr = txtPositionenCRN.Text .gsp_MRNNr = txtPositionenCRN.Text + .gsp_avisoId = Me.avisioID End With SicherheitsPos.SAVE() @@ -658,7 +652,7 @@ Public Class frmGesamtsicherheitenNEU .gsp_freitext = txtPosFreitext.Text .gsp_sicherheitsbetrag = Double.Parse(txtPosSicherheitsbetrag.Text) .gsp_warenwert = Double.Parse(txtPosWarenwert.Text) - .gsp_ATCNr = txtPositionenCRN.Text + .gsp_ATCNr = If(txtPositionenCRN.Text <> "", txtPositionenCRN.Text, Nothing) End With If checkSicherheitsbetrag() = False Then Exit Sub @@ -677,21 +671,25 @@ Public Class frmGesamtsicherheitenNEU txtPosFreitext.Text = sPos.gsp_freitext txtPosSicherheitsbetrag.Text = sPos.gsp_sicherheitsbetrag txtPosWarenwert.Text = sPos.gsp_warenwert - txtPositionenCRN.Text = sPos.gsp_ATCNr + txtPositionenCRN.Text = CStr(sPos.gsp_ATCNr) txtPosDate.Text = sPos.gsp_erstellungsdatum.ToString("dd.MM.yyyy") txtPosTime.Text = sPos.gsp_erstellungsdatum.ToString("HH:mm") currentSPos = sPos - btnDeletePos.Visible = True + 'btnDeletePos.Visible = True btnAddPos.Visible = False btnUpdatePos.Visible = True End Sub Private Sub btnDeleteSicherheit_Click(sender As Object, e As EventArgs) Handles btnDeleteSicherheit.Click Try + Dim posNr = currentSicherheit.gs_posNr + Dim ATBNr = currentSicherheit.gs_ATBNr + Dim gsNr = currentSicherheit.gs_gsNr currentSicherheit.Delete() + rearangePosNr(gsNr, ATBNr, posNr) btnUpdateSicherheit.Visible = False btnAddSicherheit.Visible = True btnDeleteSicherheit.Visible = False @@ -873,10 +871,11 @@ Public Class frmGesamtsicherheitenNEU Private Sub setSaldo() - lbloffenerSaldo.Text = "offener S-Saldo: " + lbloffenerSaldo.Text = "offener S-Betrag: €" Dim offernerSB As Double = Me.calcOffenerSicherheitsbetrag() If offernerSB <> 0 Then - lbloffenerSaldo.Text &= Math.Round(offernerSB, 2).ToString + lbloffenerSaldo.Text &= Decimal.Parse(Math.Round(offernerSB, 2)).ToString("N") + isOpen = True Else lbloffenerSaldo.Text &= "0" @@ -891,7 +890,7 @@ Public Class frmGesamtsicherheitenNEU Dim onlyOpenDT As DataTable - onlyOpenDT = dt.Select("gs_isOpen = True").CopyToDataTable + onlyOpenDT = dataTable.Select("gs_isOpen = True").CopyToDataTable For i As Integer = 0 To onlyOpenDT.Rows.Count - 1 @@ -921,16 +920,16 @@ Public Class frmGesamtsicherheitenNEU If isInList = False AndAlso onlyOpenDT.Rows.Count - 1 <> 0 Then - For i As Integer = 0 To dt.Rows.Count - 1 - If dt.Rows(i).Item("gs_gsnr") = Me.gessicherheitID Then + For i As Integer = 0 To dataTable.Rows.Count - 1 + If dataTable.Rows(i).Item("gs_gsnr") = Me.gessicherheitID Then If i = 0 Then prevGessicherheitID = -1 ' no prev Sicherheit Else For j As Integer = i To 0 - If dt.Rows(j).Item("gs_isOpen") Then - prevGessicherheitID = dt.Rows(j).Item("gs_gsnr") + If dataTable.Rows(j).Item("gs_isOpen") Then + prevGessicherheitID = dataTable.Rows(j).Item("gs_gsnr") 'MsgBox("prevGessicherheitID " & prevGessicherheitID) Exit For End If @@ -938,12 +937,12 @@ Public Class frmGesamtsicherheitenNEU End If - If i = dt.Rows.Count - 1 Then + If i = dataTable.Rows.Count - 1 Then nextGessicherheitID = -1 ' ' no next Sicherheit Else - For k As Integer = i To dt.Rows.Count - 1 - If dt.Rows(k).Item("gs_isOpen") Then - nextGessicherheitID = dt.Rows(k).Item("gs_gsnr") + For k As Integer = i To dataTable.Rows.Count - 1 + If dataTable.Rows(k).Item("gs_isOpen") Then + nextGessicherheitID = dataTable.Rows(k).Item("gs_gsnr") 'MsgBox("nextGessicherheitID " & nextGessicherheitID) Exit For End If @@ -961,16 +960,16 @@ Public Class frmGesamtsicherheitenNEU Private Function setPrevAndNextGesAll() - For i As Integer = 0 To dt.Rows.Count - 1 - If dt.Rows(i).Item("gs_gsnr") = Me.gessicherheitID Then + For i As Integer = 0 To dataTable.Rows.Count - 1 + If dataTable.Rows(i).Item("gs_gsnr") = Me.gessicherheitID Then - prevGessicherheitID = dt.Rows(i).Item("gs_gsnr") - 1 + prevGessicherheitID = dataTable.Rows(i).Item("gs_gsnr") - 1 - nextGessicherheitID = dt.Rows(i).Item("gs_gsnr") + 1 + nextGessicherheitID = dataTable.Rows(i).Item("gs_gsnr") + 1 If i = 0 Then prevGessicherheitID = -1 ' no prev Sicherheit - If i = dt.Rows.Count - 1 Then nextGessicherheitID = -1 ' ' no next Sicherheit + If i = dataTable.Rows.Count - 1 Then nextGessicherheitID = -1 ' ' no next Sicherheit 'MsgBox("prevGessicherheitID " & prevGessicherheitID) 'MsgBox("nextGessicherheitID " & nextGessicherheitID) @@ -1096,7 +1095,37 @@ Public Class frmGesamtsicherheitenNEU End Sub + Private Sub rearangePosNr(gsNr As Integer, ATBNr As String, posNr As Integer) + + If posNr = -1 Or posNr = 1 Then Exit Sub + + Dim sqlq As String = "select [gs_gsId], [gs_posNr] from [tblGesamtsicherheit] where gs_gsnr = " & gsNr & " AND gs_ATBNR = '" & ATBNr & "' AND gs_posNr > '" & posNr & "'" + Dim dt As New DataTable + dt = SQL.loadDgvBySql(sqlq, "AVISO", 100, True) + + If (dt.Rows.Count = 0) Then Exit Sub + For i As Integer = 0 To dt.Rows.Count - 1 + MsgBox("gs_gsId: " & dt.Rows(i).Item("gs_gsId").ToString & " " & "gs_posNr: " & dt.Rows(i).Item("gs_posNr").ToString) + Dim sicherheit = New cSicherheiten(dt.Rows(i).Item("gs_gsId"), dt.Rows(i).Item("gs_posNr")) + Dim currentPos = sicherheit.gs_posNr + sicherheit.gs_posNr = currentPos - 1 + sicherheit.UPDATEWithNewPosNr() + + Next + + + End Sub + + Private Sub txtlkwIdSearch_VALUE_CHANGED() Handles txtlkwIdSearch.VALUE_CHANGED + If (txtlkwIdSearch._value <> "") Then + txtLKWID.Text = txtlkwIdSearch._value + txtLKWID.ReadOnly = True + Else + txtLKWID.Clear() + txtLKWID.ReadOnly = False + End If + End Sub End Class