Loop down rows to first numerical character
Michael,
You can use the special cells method: the example below will put "This is a
number" into the adjacent cell in column D for every number in column C.
Note that the "xlCellTypeConstant" means that the numbers are actual
constants, not the values returned by formulas, which would require
"xlCellTypeFormulas" instead.
HTH,
Bernie
MS Excel MVP
Sub Example()
Dim myCell As Range
For Each myCell In Columns("C:C").SpecialCells(xlCellTypeConstants, 1)
myCell(1, 2).Value = "This is a number"
Next myCell
End Sub
"Michael McClellan" wrote in message
m...
I'm looking to build a macro that will loop down rows and then stop
and the first numerical character, modify some adjacent cells, then
move on to the next numerical character.
Does anybody have a clue?
|