View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
IanC IanC is offline
external usenet poster
 
Posts: 49
Default Unable to copy sheet

I have a macro that takes data from a list and uses this to create a model in
a separate sheet (called 'model'). It then takes a copy of that sheet
(creating 'model (2)') and then renames the model with the person's name to
whom it relates (e.g. model_john').

It then repeats the process using the next column of data.

All works well for about 20 columns/models (it is always the same number)
and then I get an error 1004 at the command:

Sheets("model").Copy Befo=Sheets("INDEX")

Furthermore, if I then try to copy a sheet manually, nothing happens.
However, if I open a new book, I can copy a sheet in that and, when I return
to the problem book, I can copy sheets again.

It is Excel XP running on Windows XP. The workbook is read only. There is
no protection applied.

Ian