View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Sean Sean is offline
external usenet poster
 
Posts: 208
Default using For each loop to populate a range

i'm trying to use a For Each loop but I can't get it to work. I don't think
that the counter is necessary but i'm not sure how this should be written.
Any help streamlining this would be appreciated.

Static counter As Integer
For Each Row In Range("TotalData")
ImplementPlace = Worksheets("Implementation
Summary").Range("ImplementPlace").Cells(2, 1)
counter = counter + 1
If Worksheets("Post-Assessment").Range("TotalData").Cells(counter,
15) = "True" Then
If Worksheets("Post-Assessment").Range("TotalData").Cells(counter,
10) = "True" Then
Worksheets("Implementation
Summary").Range("ImplementMeth").Cells(ImplementPl ace, 2) = "S"
Else
Worksheets("Implementation
Summary").Range("ImplementMeth").Cells(ImplementPl ace, 2) = "IR"
End If
Worksheets("Implementation
Summary").Range("ImplementMeth").Cells(ImplementPl ace, 3) =
Worksheets("Post-Assessment").Range("TotalData").Cells(counter, 2)
Worksheets("Implementation
Summary").Range("ImplementMeth").Cells(ImplementPl ace, 4) =
Worksheets("Post-Assessment").Range("TotalData").Cells(counter, 7)
End If

Next Row