Better colors for file grid, small tweaks

This commit is contained in:
Jonathan Jenne
2022-04-20 11:46:14 +02:00
parent 1bef72d65c
commit f87b1018de
3 changed files with 30 additions and 10 deletions

View File

@@ -136,17 +136,36 @@ Public Class frmImportMain
#Region "Grid Events"
Private Sub GridViewFiles_CustomDrawCell(sender As Object, e As Views.Base.RowCellCustomDrawEventArgs) Handles GridViewFiles.CustomDrawCell
Dim oDocument As Document = GridViewFiles.GetRow(e.RowHandle)
Try
Dim oDocument As Document = GridViewFiles.GetRow(e.RowHandle)
If oDocument.HasErrors Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.LightCoral
End If
If oDocument.Equals(CurrentDocument) Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.LightYellow
End If
If oDocument.Imported Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.LightGreen
End If
If oDocument.HasErrors Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.LightCoral
End If
If oDocument.HasErrors And oDocument.Equals(CurrentDocument) Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.Coral
End If
If oDocument.Imported Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.LightGreen
End If
If oDocument.Imported And oDocument.Equals(CurrentDocument) Then
e.Appearance.Options.UseBackColor = True
e.Appearance.BackColor = Color.Green
End If
Catch ex As Exception
Logger.Error(ex)
End Try
End Sub
Private Sub GridView_CustomDrawCell(sender As Object, e As Views.Base.RowCellCustomDrawEventArgs)