Microsoft Excel - Macros - Colors - Check Color

Function CheckColour(range)
  If range.Interior.ColorIndex = 6 Then
      CheckColour = 1
  ElseIf range.Interior.ColorIndex = 43 Then
      CheckColour = 2
  ElseIf range.Interior.ColorIndex = 19 Then
      CheckColour = 3
  ElseIf range.Interior.ColorIndex = 47 Then
      CheckColour = 4
  ElseIf range.Interior.ColorIndex = 24 Then
      CheckColour = 5
  ElseIf range.Interior.ColorIndex = -4142 Then
      CheckColour = 6
  ElseIf range.Interior.ColorIndex = 33 Then
      CheckColour = 7
  Else
      CheckColour = "Unknown"
  End If
End Function