Private Sub RefreshColor() Dim I, J As Integer '已出车或正在维修中的车作醒目的显示 With mfgVehicleStatus For I = 1 To .Rows - 1 If .TextMatrix(I, 3) = "出车" Or .TextMatrix(I, 3) = "维修" Then .Row = I For J = 1 To .Cols - 1 .Col = J .CellForeColor = vbRed Next End If Next .Col = 1 End With End Sub
Dim I, J As Integer
'已出车或正在维修中的车作醒目的显示
With mfgVehicleStatus
For I = 1 To .Rows - 1
If .TextMatrix(I, 3) = "出车" Or .TextMatrix(I, 3) = "维修" Then
.Row = I
For J = 1 To .Cols - 1
.Col = J
.CellForeColor = vbRed
Next
End If
Next
.Col = 1
End With
End Sub