Hi All,
I have a VBA Code which sets Conditional Formatting for a range.
But it's not working as it should be.
Can anybody please have a look at attached file and suggest a solution.
In the file, only one function is written as below:
Sub setCondFormat()
Cells.FormatConditions.Delete
With Range("B3:H62")
.FormatConditions.Add Type:=xlExpression, Formula1:="=IF($D3="""",FALSE,IF($F3>=$E3,TRUE,FALSE))"
With .FormatConditions(.FormatConditions.Count)
.SetFirstPriority
.Interior.Color = RGB(215, 228, 188)
End With
End With
End Sub
Following is the conditional formatting rules in simple english:
1. If Cell in column D is blank, no formatting should be applied.
2. If Cell in column F is >= Cell in column E, that whole row should become green.
Kindly help!
Bookmarks