View Single Post
  #5   Report Post  
Posted to microsoft.public.excel.programming,microsoft.public.excel.worksheet.functions
rudawg
 
Posts: n/a
Default Slow data filtering

Richard,

I am glad you solved your issue.........In reading your post, it appears you
were having trouble with something similar to what I am trying to do. In
this same forum, I have posted a question titled "Filtered List to New
Worksheet". Would you review that question and let me know if it is similar
to what you are succesfully doing in your workbook.

Thanks
Rudy

"Richard Buttrey" wrote:

Hi,

I'm hoping someone can help me out.

I've been running a data filter macro

Range("hist_data").AdvancedFilter Action:=xlFilterCopy, _
criteriarange:=Range("job_crit"), _
copytorange:=Range("hist_out"), unique:=False

sucessfully for a couple of years. By successfully I mean that the
line above used to be actioned instantaneously as I F8 through it.

However in attempting to deduce why the macro that calls this code
(which loops about 400 times) was taking so long, I now find that
these two lines of code are taking about 6 seconds.

I originally thought that the database being filtered, now at about
30,000 rows, might be contributing to the problem. But I've taken a
copy of the database to a new blank workbook, closed the original
workbook and created the appropriate range names in the new workbook
and it works as normal, i.e. instantaneously. When I re-open the first
workbook however the problem of slow running has returned.

Has anyone any ideas for curing this? This is beginning to cause me
serious time problems.

The first workbook consist of about 20 worksheets and is about 30 MB
in size, and contains about 250 defined range names.

I'm using Windows 2000 and Excel 2002 SP3 if that helps in any way.

Usual TIA

Regards




Richard Buttrey
__