View Single Post
  #2   Report Post  
Posted to microsoft.public.excel.programming
Mike H Mike H is offline
external usenet poster
 
Posts: 11,501
Default looping through range

Hi,

There are several ways of which this one may meet your needs

Sub versive()
Set myrange = Range("A1:A10") 'Change to suit
For Each c In myrange
If IsEmpty(c) Then
c.Value = Date
End If
Next
End Sub

Mike

" wrote:

I have a range withing a list, i wish to loop throught the range
without activating the cells and in each blank cell put todays date
in. I am using a do loop but I am struggling, possible need a for loop
but I am not to good on these, any advice much grateful

John