jmckeone
Well-known Member
- Joined
- Jun 3, 2006
- Messages
- 550
What I'd like to do is begin at the top of the page and stop at each blank row and then delete any conditional formats which exist and then re-format as follows:
Here's what it looks like to begin with. The other trick being how to tell it to stop when it gets to the bottom of the available data.
Code:
Sub BlankRowFormats()
' BlankRowFormats Macro
' Macro recorded 7/25/2007 by E012884
Range("A2").Select
Range("A2:Y2").Select
Selection.FormatConditions.Delete
Selection.Interior.ColorIndex = 40
Selection.Font.ColorIndex = 0
Selection.Font.Bold = True
Range("A2:K2").Select
Range("K2").Activate
With Selection
.HorizontalAlignment = xlLeft
End With
Range("L2:Y2").Select
With Selection
.HorizontalAlignment = xlRight
End With
Range("A2").Select
ActiveCell.FormulaR1C1 = "=R[1]C"
End Sub
Here's what it looks like to begin with. The other trick being how to tell it to stop when it gets to the bottom of the available data.