Thread: Highlight Rows
View Single Post
  #3   Report Post  
Posted to microsoft.public.excel.programming
Don Guillett[_2_] Don Guillett[_2_] is offline
external usenet poster
 
Posts: 1,522
Default Highlight Rows

Sub colorif()
Dim c As Range
For Each c In Range("e1:e21")
If c = "pending" Then c.EntireRow.Interior.ColorIndex = 6
Next c
End Sub
--
Don Guillett
Microsoft MVP Excel
SalesAid Software

"Napoleon Vang" <Napoleon
wrote in message
...
Is there a way to program an expression close to... If cell in column E
equals string of text "Pending", select entire row and change background
color/patern to yellow?