Thread: Paste
View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Ram Ram is offline
external usenet poster
 
Posts: 138
Default Paste

Can someone show me how the results from the following code can be pasted all
at the same time instead of pasting in one cell at a time.


Dim J As Integer

For J = 1 To 2

Worksheets("main").Range("B" & 17 + J).Value =
Evaluate("=SUMPRODUCT((AGTHistory!A1:A11000=A" & 17 + J &
")*(AGTHistory!C1:C11000=Main!B5),AGTHistory!K1:K1 1000)")
Worksheets("main").Range("C" & 17 + J).Value =
Evaluate("=SUMPRODUCT((AGTHistory!A1:A11000=A" & 17 + J &
")*(AGTHistory!C1:C11000=Main!B5),AGTHistory!L1:L1 1000)")
Next J


End Sub

Thanks for all your help