ClimoC
Well-known Member
- Joined
- Aug 21, 2009
- Messages
- 584
Hey
Got this code returning the Invalid or Unqualified error.
It highlights the first formatting bit ".ColorIndex = 1" for the first statement, "If Cell value is blank ("")"
Can anyone help me on this? I don't see what the problem is with it...
Cheers
C
Got this code returning the Invalid or Unqualified error.
Code:
Private Sub Worksheet_Change(ByVal Target As Range)
If Not Intersect(Target, Range("AS6:BX500")) Is Nothing Then
Application.ScreenUpdating = False
Application.EnableEvents = False
Set MyGrid = Range("AS6:BX500")
For Each Cell In MyGrid
If Cell.Value = "" Then
.ColorIndex = 1
.Pattern = xlGrid
.PatternColorIndex = 51
End If
If Cell.Value = "D/L" Then
Cell.Interior.ColorIndex = 41
End If
If Cell.Value = "Last Chance" Then
Cell.Interior.ColorIndex = 48
End If
If Cell.Value > "0.0000001" And Cell.Value < "1000000000.00" Then
Cell.Interior.ColorIndex = 5
If Cell.Value <> "" And Cell.Value <> "D/L" And Cell.Value <> "Last Chance" And Cell.Value < "0.0000001" And Cell.Value > "1000000000.00" Then
Cell.Interior.ColorIndex = 3
End If
Exit For
Next
Application.EnableEvents = True
Application.ScreenUpdating = False
End Sub
It highlights the first formatting bit ".ColorIndex = 1" for the first statement, "If Cell value is blank ("")"
Can anyone help me on this? I don't see what the problem is with it...
Cheers
C