求助贴吧各位,简单的几句代码,但是订单只要是百分百完成的,那个单元格就变成空白了,我改成千分制的话,也是空白不显示,没有头绪
Sub 判定进度()
Dim i As Integer
Dim x As Integer
Dim h As Integer
Dim max As Integer
max = Range("a12").End(xlDown).Row
h = 12
For h = 12 To max
x = 0
For i = 1 To 11
If ActiveSheet.Cells(h, 7 + i).Interior.Color = RGB(198, 224, 180) Or ActiveSheet.Cells(h, 7 + i).Interior.Color = RGB(208, 206, 206) Then
x = x + 1
Else
Cells(h, "G") = x / 11
Exit For
End If
Next
Next
End Sub
Sub 判定进度()
Dim i As Integer
Dim x As Integer
Dim h As Integer
Dim max As Integer
max = Range("a12").End(xlDown).Row
h = 12
For h = 12 To max
x = 0
For i = 1 To 11
If ActiveSheet.Cells(h, 7 + i).Interior.Color = RGB(198, 224, 180) Or ActiveSheet.Cells(h, 7 + i).Interior.Color = RGB(208, 206, 206) Then
x = x + 1
Else
Cells(h, "G") = x / 11
Exit For
End If
Next
Next
End Sub