autofilter using array

dgrosen

Board Regular
Joined
May 3, 2003
Messages
110
I need help with the following.
I have 2 sheets. Sheet1 has an array of numbers (A1:J18). I need to use these to filter the data on sheet2 to show only those present on Sheet1
The number on sheet1 are on cells A1:J18 and those match the value on column B on sheet2.
Any help will be very much appreciated
Thanks
 

Excel Facts

When did Power Query debut in Excel?
Although it was an add-in in Excel 2010 & Excel 2013, Power Query became a part of Excel in 2016, in Data, Get & Transform Data.

ukmikeb

Well-known Member
Joined
Jul 10, 2009
Messages
2,757
Hi

It would be easier if you could organise your array into a single column (A) then in a spare column on Sheet 2 enter :-

Code:
=--($B1=Sheet1!$A$1:$A$180)

with Control-Shift-Enter and copy down assuming that the first number is in Cell B1.

Then Filter for "1" in the spare column.

hth

Mike
 
Last edited:

AlphaFrog

MrExcel MVP
Joined
Sep 2, 2009
Messages
16,450
Same concept as ukmikeb except the formula is not an array formula
=COUNTIF(Sheet1!$A$1:$J$18,B1)>0
 
Last edited:
Master Excel Bundle

Excel contains over 450 functions, with more added every year. That’s a huge number, so where should you start? Right here with this bundle.

Forum statistics

Threads
1,163,700
Messages
5,833,213
Members
430,197
Latest member
edeibold

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Top