berlinhammer
Board Regular
- Joined
- Jan 30, 2009
- Messages
- 187
Hello,
I posted a question on a different area of the macro I'm working on, but I think this is a different issue altogether so I hope it warrants another thread.
My macro loops through my worksheets in my workbook (wbO), it copies them, if they pass certain criteria they are moved to a new workbook I create at the beginning of the macro (wbN), if they fail they are deleted.
My macro keeps tripping after about 7 sheets, I do not think my sheets are protected at all.
ERROR (paraphrased)
Run time 1004
Method 'Move' of object 'Worksheet' failed
The strange thing I have found is that as the macro hangs in debug mode, I seem to be able to move the sheet manually to a another new book, and then back from the new book to wbO but if I try to move anything to wbN it simply does not do anything.
The only conclusion I can draw from this is that wbN does not want any more sheets, has it hit some kind of limit? I seem to be able to copy or move sheets or whatever but just not into wbN.
I'm puzzled by this, it would be interesting to know if anyone has experience anything similar or knows how I can fix it?
Thanks
Jon
I posted a question on a different area of the macro I'm working on, but I think this is a different issue altogether so I hope it warrants another thread.
My macro loops through my worksheets in my workbook (wbO), it copies them, if they pass certain criteria they are moved to a new workbook I create at the beginning of the macro (wbN), if they fail they are deleted.
My macro keeps tripping after about 7 sheets, I do not think my sheets are protected at all.
ERROR (paraphrased)
Run time 1004
Method 'Move' of object 'Worksheet' failed
The strange thing I have found is that as the macro hangs in debug mode, I seem to be able to move the sheet manually to a another new book, and then back from the new book to wbO but if I try to move anything to wbN it simply does not do anything.
The only conclusion I can draw from this is that wbN does not want any more sheets, has it hit some kind of limit? I seem to be able to copy or move sheets or whatever but just not into wbN.
I'm puzzled by this, it would be interesting to know if anyone has experience anything similar or knows how I can fix it?
Thanks
Jon