How to set a cell value = to whats looping?

Posted by digitalgavakie on Stack Overflow See other posts from Stack Overflow or by digitalgavakie
Published on 2011-11-21T17:38:56Z Indexed on 2011/11/21 17:50 UTC
Read the original article Hit count: 133

Filed under:
|
|

I have this code below. How can I set a cell value to = whats looping through that value?

Sub Test2()
      ' Select cell A2, *first line of data*.
      Range("A2").Select
      ' Set Do loop to stop when an empty cell is reached.
      Do Until IsEmpty(ActiveCell)
         ' Insert your code here.
         ' Step down 1 row from present location.
         ActiveCell.Offset(1, 0).Select
      Loop
   End Sub

© Stack Overflow or respective owner

Related posts about excel

Related posts about excel-vba