Private Sub grdDataGrid_FetchCellStyle(ByVal Condition As Integer, ByVal Split As Integer, Bookmark As Variant, ByVal Col As Integer, ByVal CellStyle As TrueDBGrid60.StyleDisp)
With grdDataGrid
If .Columns(Col).CellText(Bookmark) = "5" Then
CellStyle.BackColor = RGB(255, 255, 0)
End If
If .Columns(Col).CellText(Bookmark) = "6" Then
CellStyle.BackColor = RGB(0, 255, 255)
End If
If .Columns(Col).CellText(Bookmark) = "7" Then
CellStyle.BackColor = RGB(255, 0, 255)
End If
End With
End Sub
希望對你有幫助