Trying to thru the cells (F2 - F75) and select those with a number in the cell then center, bold and set a yellow BG for cells containing numbers
Any help appreciated
Code:
-----go thru the cells (F2 - F75) and select those with a number in the cell------
Set rng = Range("F2:F75")
For Each cell In rng
'----------if the cell contains a number then------------
If IsNumeric(c) Then
'---center, bold and set a yellow BG for cells containing numbers-------
ActiveCell.Select
With Selection.Interior
.Pattern = xlSolid
.PatternColorIndex = xlAutomatic
.Color = 65535
.TintAndShade = 0
.PatternTintAndShade = 0
End With
Selection.Font.Bold = True
With Selection
.HorizontalAlignment = xlCenter
.VerticalAlignment = xlBottom
.WrapText = False
.Orientation = 0
.AddIndent = False
.IndentLevel = 0
.ShrinkToFit = False
.ReadingOrder = xlContext
.MergeCells = False
End With
End If
Next
Any help appreciated