View Single Post
  #1   Report Post  
Posted to microsoft.public.excel.programming
Daniel Bonallack[_2_] Daniel Bonallack[_2_] is offline
external usenet poster
 
Posts: 27
Default Error Handler not handling error...

I have code that loops through a workbook, copies the
contents of each sheet and pastes it to another workbook.

For each sheet I have this line:
ActiveSheet.ShowAllData

Most of the sheets are not filtered, so at this line the
code jumps into the error handler, where "Resume Next" is
waiting to push it back up into the loop.

The problem is this:
On the eighth sheet without filters, I get a debug error
on the ShowAllData line - it's like the errors are
stacking up. Can someone tell me what's happening, and
how to avoid this problem?

Thanks in advance.
Daniel