Fehlerhandling verbessert -> falsche von Nutzer eingegebene Werte werden in div. Spalten geprüft/entfernt.
This commit is contained in:
@@ -113,11 +113,13 @@ Public Class frmGesamtsicherheitenMenuNEU
|
||||
|
||||
|
||||
For Each row As DataGridViewRow In dgvListe.Rows
|
||||
If row.Cells("gs_SicherheitsSaldo").Value <> 0 Then
|
||||
If Not IsDBNull(row.Cells("gs_SicherheitsSaldo").Value) Then
|
||||
If row.Cells("gs_SicherheitsSaldo").Value <> 0 Then
|
||||
|
||||
dataTable.Rows.Add(row.Cells("gs_gsnr").Value, True)
|
||||
Else
|
||||
dataTable.Rows.Add(row.Cells("gs_gsnr").Value, False)
|
||||
dataTable.Rows.Add(row.Cells("gs_gsnr").Value, True)
|
||||
Else
|
||||
dataTable.Rows.Add(row.Cells("gs_gsnr").Value, False)
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
|
||||
@@ -130,11 +132,12 @@ Public Class frmGesamtsicherheitenMenuNEU
|
||||
|
||||
|
||||
For Each row As DataGridViewRow In dgvListe.Rows
|
||||
|
||||
If row.Cells("gs_SicherheitsSaldo").Value <> 0 Then
|
||||
row.DefaultCellStyle.BackColor = Color.Red
|
||||
Else
|
||||
row.DefaultCellStyle.BackColor = Color.Green
|
||||
If Not IsDBNull(row.Cells("gs_SicherheitsSaldo").Value) Then
|
||||
If row.Cells("gs_SicherheitsSaldo").Value <> 0 Then
|
||||
row.DefaultCellStyle.BackColor = Color.Red
|
||||
Else
|
||||
row.DefaultCellStyle.BackColor = Color.Green
|
||||
End If
|
||||
End If
|
||||
Next
|
||||
|
||||
|
||||
Reference in New Issue
Block a user