From e1ceb47c39a24efdc822dd28c0adb487c95c1967 Mon Sep 17 00:00:00 2001 From: "d.breimaier" Date: Thu, 8 Aug 2024 08:06:31 +0200 Subject: [PATCH] Qualitaetskontrolle Bar --- .../usrCntlQualitaetskontrolle.Designer.vb | 84 +++++++++---------- .../usrCntlQualitaetskontrolle.resx | 15 ---- .../usrCntlQualitaetskontrolle.vb | 30 +++---- 3 files changed, 55 insertions(+), 74 deletions(-) diff --git a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.Designer.vb b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.Designer.vb index 48140146..50eeec01 100644 --- a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.Designer.vb +++ b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.Designer.vb @@ -22,15 +22,15 @@ Partial Class usrCntlQualitaetskontrolle 'Das Bearbeiten mit dem Code-Editor ist nicht möglich. Private Sub InitializeComponent() - Dim DataGridViewCellStyle10 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle11 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle12 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle13 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle14 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle15 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle16 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle17 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() - Dim DataGridViewCellStyle18 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle19 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle20 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle21 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle22 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle23 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle24 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle25 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle26 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() + Dim DataGridViewCellStyle27 As System.Windows.Forms.DataGridViewCellStyle = New System.Windows.Forms.DataGridViewCellStyle() Me.Label46 = New System.Windows.Forms.Label() Me.Button2 = New System.Windows.Forms.Button() Me.Label40 = New System.Windows.Forms.Label() @@ -563,10 +563,10 @@ Partial Class usrCntlQualitaetskontrolle ' 'pos ' - DataGridViewCellStyle10.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight - DataGridViewCellStyle10.Format = "N0" - DataGridViewCellStyle10.NullValue = Nothing - Me.pos.DefaultCellStyle = DataGridViewCellStyle10 + DataGridViewCellStyle19.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight + DataGridViewCellStyle19.Format = "N0" + DataGridViewCellStyle19.NullValue = Nothing + Me.pos.DefaultCellStyle = DataGridViewCellStyle19 Me.pos.Frozen = True Me.pos.HeaderText = "Position" Me.pos.MaxInputLength = 3 @@ -592,10 +592,10 @@ Partial Class usrCntlQualitaetskontrolle ' 'gewicht ' - DataGridViewCellStyle11.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight - DataGridViewCellStyle11.Format = "N2" - DataGridViewCellStyle11.NullValue = Nothing - Me.gewicht.DefaultCellStyle = DataGridViewCellStyle11 + DataGridViewCellStyle20.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight + DataGridViewCellStyle20.Format = "N2" + DataGridViewCellStyle20.NullValue = Nothing + Me.gewicht.DefaultCellStyle = DataGridViewCellStyle20 Me.gewicht.HeaderText = "Gewicht" Me.gewicht.MaxInputLength = 100 Me.gewicht.Name = "gewicht" @@ -847,10 +847,10 @@ Partial Class usrCntlQualitaetskontrolle ' 'DataGridViewTextBoxColumn1 ' - DataGridViewCellStyle12.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight - DataGridViewCellStyle12.Format = "N0" - DataGridViewCellStyle12.NullValue = Nothing - Me.DataGridViewTextBoxColumn1.DefaultCellStyle = DataGridViewCellStyle12 + DataGridViewCellStyle21.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight + DataGridViewCellStyle21.Format = "N0" + DataGridViewCellStyle21.NullValue = Nothing + Me.DataGridViewTextBoxColumn1.DefaultCellStyle = DataGridViewCellStyle21 Me.DataGridViewTextBoxColumn1.Frozen = True Me.DataGridViewTextBoxColumn1.HeaderText = "Position" Me.DataGridViewTextBoxColumn1.MaxInputLength = 3 @@ -872,20 +872,20 @@ Partial Class usrCntlQualitaetskontrolle 'DataGridViewTextBoxColumn4 ' Me.DataGridViewTextBoxColumn4.AutoSizeMode = System.Windows.Forms.DataGridViewAutoSizeColumnMode.Fill - DataGridViewCellStyle13.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight - DataGridViewCellStyle13.Format = "N2" - DataGridViewCellStyle13.NullValue = Nothing - Me.DataGridViewTextBoxColumn4.DefaultCellStyle = DataGridViewCellStyle13 + DataGridViewCellStyle22.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight + DataGridViewCellStyle22.Format = "N2" + DataGridViewCellStyle22.NullValue = Nothing + Me.DataGridViewTextBoxColumn4.DefaultCellStyle = DataGridViewCellStyle22 Me.DataGridViewTextBoxColumn4.HeaderText = "Gewicht" Me.DataGridViewTextBoxColumn4.MaxInputLength = 100 Me.DataGridViewTextBoxColumn4.Name = "DataGridViewTextBoxColumn4" ' 'DataGridViewTextBoxColumn5 ' - DataGridViewCellStyle14.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight - DataGridViewCellStyle14.Format = "N2" - DataGridViewCellStyle14.NullValue = Nothing - Me.DataGridViewTextBoxColumn5.DefaultCellStyle = DataGridViewCellStyle14 + DataGridViewCellStyle23.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleRight + DataGridViewCellStyle23.Format = "N2" + DataGridViewCellStyle23.NullValue = Nothing + Me.DataGridViewTextBoxColumn5.DefaultCellStyle = DataGridViewCellStyle23 Me.DataGridViewTextBoxColumn5.HeaderText = "Gewicht" Me.DataGridViewTextBoxColumn5.MaxInputLength = 100 Me.DataGridViewTextBoxColumn5.Name = "DataGridViewTextBoxColumn5" @@ -1061,37 +1061,37 @@ Partial Class usrCntlQualitaetskontrolle ' 'gew ' - DataGridViewCellStyle15.Format = "N2" - DataGridViewCellStyle15.NullValue = Nothing - Me.gew.DefaultCellStyle = DataGridViewCellStyle15 + DataGridViewCellStyle24.Format = "N2" + DataGridViewCellStyle24.NullValue = Nothing + Me.gew.DefaultCellStyle = DataGridViewCellStyle24 Me.gew.HeaderText = "Gewicht" Me.gew.Name = "gew" Me.gew.ReadOnly = True ' 'Preis ' - DataGridViewCellStyle16.Format = "C2" - DataGridViewCellStyle16.NullValue = Nothing - Me.Preis.DefaultCellStyle = DataGridViewCellStyle16 + DataGridViewCellStyle25.Format = "C2" + DataGridViewCellStyle25.NullValue = Nothing + Me.Preis.DefaultCellStyle = DataGridViewCellStyle25 Me.Preis.HeaderText = "Preis" Me.Preis.Name = "Preis" Me.Preis.ReadOnly = True ' 'Faktor ' - DataGridViewCellStyle17.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter - DataGridViewCellStyle17.Format = "N0" - DataGridViewCellStyle17.NullValue = Nothing - Me.Faktor.DefaultCellStyle = DataGridViewCellStyle17 + DataGridViewCellStyle26.Alignment = System.Windows.Forms.DataGridViewContentAlignment.MiddleCenter + DataGridViewCellStyle26.Format = "N0" + DataGridViewCellStyle26.NullValue = Nothing + Me.Faktor.DefaultCellStyle = DataGridViewCellStyle26 Me.Faktor.HeaderText = "Faktor" Me.Faktor.Name = "Faktor" Me.Faktor.ReadOnly = True ' 'Betrag ' - DataGridViewCellStyle18.Format = "C2" - DataGridViewCellStyle18.NullValue = Nothing - Me.Betrag.DefaultCellStyle = DataGridViewCellStyle18 + DataGridViewCellStyle27.Format = "C2" + DataGridViewCellStyle27.NullValue = Nothing + Me.Betrag.DefaultCellStyle = DataGridViewCellStyle27 Me.Betrag.HeaderText = "Betrag" Me.Betrag.Name = "Betrag" Me.Betrag.ReadOnly = True diff --git a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.resx b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.resx index f5f4cc74..977c57ee 100644 --- a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.resx +++ b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.resx @@ -168,19 +168,4 @@ True - - True - - - True - - - True - - - True - - - True - \ No newline at end of file diff --git a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.vb b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.vb index 5808585c..f881c393 100644 --- a/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.vb +++ b/SDL/Formulare/KDFormulare/FormulareBaukasten/usrCntlQualitaetskontrolle.vb @@ -411,11 +411,8 @@ Public Class usrCntlQualitaetskontrolle If dgvGebuehren.Rows.Count = 0 Then Exit Sub - - Dim PERSONAL As SDL.cPersonal = Nothing Dim frmSecureLoginKassenbuch As New SDL.frmSecureLoginKassenbuch - ' frmSecureLoginKassenbuch.KassenbuchNr_tmp = PERSONAL.KassenbuchNr If frmSecureLoginKassenbuch.ShowDialog(Me) = DialogResult.OK Then PERSONAL = frmSecureLoginKassenbuch.PERSONAL Dim f As New frmBelegNeu(PERSONAL, Nothing, "E") @@ -423,13 +420,10 @@ Public Class usrCntlQualitaetskontrolle AddHandler f.LOADED, Sub() f.AddPositions(dgvGebuehren, False) End Sub - f.ShowDialog(Me) - End If - End Sub Private Sub initdgvGebuehren() @@ -443,6 +437,11 @@ Public Class usrCntlQualitaetskontrolle Dim sumNormenAllg As Double = 0 Dim sumNormenSpez As Double = 0 + Dim antrag, verzicht, idk As Double + antrag = 40.7 + verzicht = 9.3 + idk = 39.4 + For Each r As DataGridViewRow In dgvPositionen.Rows @@ -453,10 +452,10 @@ Public Class usrCntlQualitaetskontrolle If r.Cells(5).Value <> "" Then For Each row As DataRow In normenSpeziell.Rows - Dim code = row("kncode") - Dim seachedCode = r.Cells(5).Value - seachedCode = seachedCode.ToString.Substring(0, code.Length) - If row("kncode") = seachedCode Then + Dim code = row("kncode").trim() + Dim searchedCode = r.Cells(5).Value + searchedCode = searchedCode.ToString.Substring(0, code.Length) + If row("kncode") = searchedCode Then sumNormenSpez += r.Cells(4).Value found = True Exit For @@ -466,9 +465,9 @@ Public Class usrCntlQualitaetskontrolle If Not found Then For Each row As DataRow In normenAllg.Rows - Dim code = row("kncode") - Dim seachedCode = r.Cells(5).Value - If seachedCode = seachedCode.ToString.Substring(0, code.Length) Then + Dim code = row("kncode").trim() + Dim searchedCode = r.Cells(5).Value + If searchedCode = searchedCode.ToString.Substring(0, code.Length) Then sumNormenAllg += r.Cells(4).Value found = True Exit For @@ -496,10 +495,7 @@ Public Class usrCntlQualitaetskontrolle dgvGebuehren.Rows.Add("Speziell", sumNormenSpez, NormenpreisSpez, anzSpez, anzSpez * NormenpreisSpez) End If - Dim antrag, verzicht, idk As Double - antrag = 40.7 - verzicht = 9.3 - idk = 39.4 + If cbxVerzicht.Checked Then