copy worksheet

  • Thread starter Thread starter christian
  • Start date Start date
C

christian

I need to copy a worksheet several hundred times but can
only manage to copy 1 initially. Is there an easy way to
do this apart from copy to 2 then 4 then 8 etc. Thanks
 
Manually, copy one, then copy 2, then copy 4 is the only
way to go, but a macro may make life easier. Then there's
the problem of naming the sheets. Do you want them simply
numbered? For this, I took an empty workbook, named a
sheet 1, then deleted the other two default sheets. This
will then create 99 copies of the sheet and number them 2
to 100.

Sub CopySheets()

For A = 2 To 100
Sheets("1").Copy After:=Sheets(A - 1)
Sheets("1 (2)").Name = A
Next

End Sub
 
Christian

One method. Copy/paste this code to a general module then run.

Note: "several hundred times" seems excessive. Are you sure you want this
many sheets in a single workbook?

Sub CopySheet()
Dim x As Integer
For x = 1 To 50 ' or any other value
Sheets("Sheet1").Copy After:=Sheets(1)
Next x
End Sub

The code will give you Sheet1(2), Sheet1(3) etc.

Gord Dibben Excel MVP - XL97 SR2 & XL2002
 
Back
Top