Hi to all and thank in advance for your help.
I need your help in something. I want to create a loop which will do the following
Select "Virgin new num" sheet
Select Range A7:A1507 from "Virgin new num" sheet
Copy Range from A7:A1507,
Select "Data" Sheet
Paste Special to A7
Select "Virgin new num" sheet
Select K1 cell
Delete (each time that I delete the K1 cell in generates a new set of random numbers in A7:A1507).
This loop must do the same except the fact that I need each time it loops, it should paste the A7:1507 dataset of in the adjacent cell of "Data" Sheet. So the first time it must paste it in A7, the second in B7, the third in C7 etc.
I Have created the steps in the following macro, but I don't know how to loop it
Sheets("Virgin new num").Select
Range("A7:A1507").Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Copy
Sheets("Data").Select
Range("A7").Select
Selection.PasteSpecial Paste:=xlPasteValues, Operation:=xlNone, SkipBlanks _
:=False, Transpose:=False
Sheets("Virgin new num").Select
Range("K1").Select
Application.CutCopyMode = False
Selection.ClearContents
End Sub
P.S. I must also have a way to end the loop whenever I want
Bookmarks