If Range("A18") <> "" Then
Select Case Range("A18")
Case 0 To 40
Range("A18").Interior.ColorIndex = 3
Range("A18").Interior.Pattern = xlSolid
Case 41 To 60
Range("A18").Interior.ColorIndex = 6
Range("A18").Interior.Pattern = xlSolid
Case 61 To 100
Range("A18").Interior.ColorIndex = 4
Range("A18").Interior.Pattern = xlSolid
Case Else
MsgBox "The number entered is not valid.", vbOKOnly, "Invalid Entry"
End Select
Else: End If