Private Sub CommandButton1_Click()
Dim l As Integer
Application.ScreenUpdating = False
For l = 3 To Range("C1000").End(xlUp).Row
If MyColor(Cells(l, 3)) = 35 Then
Cells(l, 2).Value = 1
ElseIf MyColor(Cells(l, 3)) = 56 Then
Cells(l, 2).Value = 2
ElseIf MyColor(Cells(l, 3)) = 36 Then
Cells(l, 2).Value = 3
ElseIf MyColor(Cells(l, 3)) = 38 Then
Cells(l, 2).Value = 4
ElseIf MyColor(Cells(l, 3)) = 37 Then
Cells(l, 2).Value = 5
ElseIf MyColor(Cells(l, 3)) = 39 Then
Cells(l, 2).Value = 6
ElseIf MyColor(Cells(l, 3)) = 4142 Then
Cells(l, 2).Value = 7
End If
Next l
Application.ScreenUpdating = True
End Sub