View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming
Brian Taylor Brian Taylor is offline
external usenet poster
 
Posts: 52
Default How to Get Date of Each Cell....

Conditional formatting would be much simpler than writing code. Have
you already tried that option?

You would need to change your code a little to make it work. Here is
some untested code to take a look at:

Sub test()
Set rng = ActiveCell.EntireRow
For Each Cell In rng
If DateValue(Cell.Value) <= (Now() - 1) Then
With Cell.Interior
.ColorIndex = 3
.Pattern = xlSolid
End With
End If
Next
End Sub