Need HELP with an auto-filter macro


Posted by Mike T. on December 22, 2001 1:59 PM

I'm a construction estimator and I need help with one of the macros I created for my estimate sheet. I choose up to 10 materials (from a list of approx. 100) by just filling in the quantity, click a button and the list auto-filters. My problem is I need the filtered items to appear on a seperate recap (summary) sheet in the same workbook. Tried Advanced Filter but it seems that only copies info. to another location on the same sheet. Can you help me?

Posted by Ivan F Moala on December 22, 2001 2:30 PM

Just copy your selection to the new destination
With your autofilter on and criteria set you should
have a selection to select.
Use something like;

Range("B4:C4").Select
Range(Selection, Selection.End(xlDown)).Select
Selection.Copy Destination:=Sheet3.[a1]

Where B4:C4 is the start of the range
Sheet3.[a1] is your top range to copy to


Ivan



Posted by Mike T on December 23, 2001 10:34 AM

Thanks Ivan, that works. I wasn't selecting the range properly (rookie). I appreciate your help and quick response.