View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
ton de w ton de w is offline
external usenet poster
 
Posts: 3
Default count of changed data

Hello,
I am using a macro to lower case selected areas.
How can I correctly print the number of cells changed, rather than
visited?

Sub lowerme()
Dim cell As Object
Dim count As Integer
count = 0
For Each cell In Selection
count = count + 1
cell.Value = LCase(cell.Value)
Next cell
MsgBox count & " Cells Changed "
End Sub

TIA

Ton