Hi,
I receive an error message when I'm creating multiple sheets with this code:
ActiveWorkbook.Sheets("Report").Copy _
After:=ActiveWorkbook.Sheets("Report")
The error message is:
Run-Time Error '1004'
Copy method of worksheet class failed.
This happens when I have copied 230 sheets. Is it a limit of the number of sheets generated or the limit is related to the size of the workbook?
I tried to execute this code into the loop but without success.
nsheets = nsheets + 1
If nsheets = 50 Then
ActiveWorkbook.Save
nsheets = 0
End If
Many thanks in advance for your kind help.
Regards,
Giovanni
I receive an error message when I'm creating multiple sheets with this code:
ActiveWorkbook.Sheets("Report").Copy _
After:=ActiveWorkbook.Sheets("Report")
The error message is:
Run-Time Error '1004'
Copy method of worksheet class failed.
This happens when I have copied 230 sheets. Is it a limit of the number of sheets generated or the limit is related to the size of the workbook?
I tried to execute this code into the loop but without success.
nsheets = nsheets + 1
If nsheets = 50 Then
ActiveWorkbook.Save
nsheets = 0
End If
Many thanks in advance for your kind help.
Regards,
Giovanni