Thursday, 5 September 2013

divide every row by VBA

divide every row by VBA

I am trying to divide every row until the last row but I am stuck at
dividing by just one row which is row 2. I was thinking of using this
Dim LastRow As Range
LastRow = Range("A" & Rows.Count).End(xlUp).Row
But my knowledge on how to make use of the range is very limited.
Do share your thoughts.. thanks! :)
My code is as follows:
Sub test1()
For Each c In Range("AL2:AS2 , BC2 ")
c.Value = c.Value / 1000
Next c
End Sub

No comments:

Post a Comment