View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
ksnapp[_37_] ksnapp[_37_] is offline
external usenet poster
 
Posts: 1
Default Why won't this code works

here is the code

Sub Total_adder()

Dim LR As Long

LR = Cells(Rows.Count, 2).End(xlUp).Row

Range("B2", Cells(LR, 2)).Select

For Each CELL In Selection
With CELL

If CELL.Value = Empty Then
CELL.Value = "TOTALS"
CELL.EntireRow.Font.Bold = True
End If
End With
Next

end sub

it runs and after it just has the range selected with no changes to th
sheet.

I need it to find all the empty cells in that range(that part works
and make the the row bold and put the word "TOTALS" in the empty cell.



Thanks in advanc

--
Message posted from http://www.ExcelForum.com