How do I convert the "A1:F47" range in code

missouridawg

New Member
Joined
Mar 7, 2019
Messages
7
to formulas?

I have a worksheet in which I want to make 300 copies of the same exact page and simply paste them below each other. Rows 1 through 47 (columns A through F) is exactly 1 page of data when printed on 8.5" x 11" paper. I want to write a script that copies that first page and pastes it directly below itself.

Page 2 would start on row 48. (1*47+1)
Page 3 would start on row 95 (2*47+1)
Page 4 would start on row 142 (3*47+1)
.
.
.
Page 300 would start on row 14101 (300*47+1)


While I am familiar with FOR loops and can set those up to do the counting in this kind of scenario, I'm having issues with converting a cell locator reference to a countable/iterative entity.

The code I'm pasting below selects the first page and copies it to the second page. How do I convert the ("A1:F47") portion of that code into using variables that can be iterated against in a FOR loop?

Range("A1:F47").Select
Selection.Copy
Range("A48").Select
ActiveSheet.Paste
 

Excel Facts

Which came first: VisiCalc or Lotus 1-2-3?
Dan Bricklin and Bob Frankston debuted VisiCalc in 1979 as a Visible Calculator. Lotus 1-2-3 debuted in the early 1980's, from Mitch Kapor.

Forum statistics

Threads
1,213,494
Messages
6,113,981
Members
448,538
Latest member
alex78

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top