VBA Copy/Paste fixed range a number of times
Solved/Closed
srinivas_kala
Posts
4
Registration date
Thursday September 19, 2019
Status
Member
Last seen
October 10, 2019
-
Updated on Sep 24, 2019 at 11:55 AM
TrowaD Posts 2921 Registration date Sunday September 12, 2010 Status Moderator Last seen January 16, 2023 - Oct 15, 2019 at 11:41 AM
TrowaD Posts 2921 Registration date Sunday September 12, 2010 Status Moderator Last seen January 16, 2023 - Oct 15, 2019 at 11:41 AM
Related:
- Vba to copy and paste a range multiple times based on cell value
- If cell contains text then return value multiple conditions ✓ - Excel Forum
- Compare two worksheets and paste differences to another sheet - excel vba free download ✓ - Excel Forum
- You've tried to log in too many times. to protect your account, a temporary block has been placed on logging in. please try again later. ✓ - Facebook Forum
- Based on the values in cells b77:b81, what function can automatically return the value in cell c77? ✓ - Excel Forum
- How to change account based in instagram - Instagram Forum
1 response
TrowaD
Posts
2921
Registration date
Sunday September 12, 2010
Status
Moderator
Last seen
January 16, 2023
549
Sep 23, 2019 at 12:07 PM
Sep 23, 2019 at 12:07 PM
Hi Srinivas,
Give the following code a try:
Best regards,
Trowa
Give the following code a try:
Sub RunMe() Dim x, dRow, Counter As Integer Counter = InputBox("How many times would you like to paste?:") dRow = 7 Range("A2:A6").Copy For x = 1 To Counter Range("A" & dRow).PasteSpecial dRow = dRow + 5 Next x Application.CutCopyMode = False End Sub
Best regards,
Trowa
Sep 27, 2019 at 11:51 AM
Thanks for the Help. Works like a champ.
Sep 27, 2019 at 01:01 PM
I need to stop the code after 200 rows(40 times to copy A1:A5). Please help.
Sep 30, 2019 at 11:48 AM
For that a few minor changes are needed:
Best regards,
Trowa
Oct 10, 2019 at 06:27 AM
Sorry for the delayed response. I was on field visit. Thank you very much. this is what I really need. Once again thank you for your time and help.
Oct 15, 2019 at 11:41 AM