ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   displaying data that does not meet criteria (https://www.excelbanter.com/excel-programming/349416-displaying-data-does-not-meet-criteria.html)

jerrystan[_7_]

displaying data that does not meet criteria
 

Is there a way (in VBA) to display/filter data that does NOT meet a lis
of criteria. Autofilter only lets me do 2 conditions, I have about 30.
Bottom line is I want to delete all rows that don't belong. I know wha
should belong but don't have a list of what doesn't. Thanks

--
jerrysta
-----------------------------------------------------------------------
jerrystan's Profile: http://www.excelforum.com/member.php...fo&userid=2857
View this thread: http://www.excelforum.com/showthread.php?threadid=49769


Bob Phillips[_6_]

displaying data that does not meet criteria
 
What you could do is to create a list of all valid criteria, and then add a
formula to check if an item is in that list. For instance, the list is in
column A, valid criteria in column J, so in B2 add a formula of

=MATCH(A2,J:J,0)

Then AUtofilter column B, and filter on the #N/A values, and delete the
visible rows.

--

HTH

RP
(remove nothere from the email address if mailing direct)


"jerrystan" wrote
in message ...

Is there a way (in VBA) to display/filter data that does NOT meet a list
of criteria. Autofilter only lets me do 2 conditions, I have about 30.
Bottom line is I want to delete all rows that don't belong. I know what
should belong but don't have a list of what doesn't. Thanks.


--
jerrystan
------------------------------------------------------------------------
jerrystan's Profile:

http://www.excelforum.com/member.php...o&userid=28573
View this thread: http://www.excelforum.com/showthread...hreadid=497694





All times are GMT +1. The time now is 01:50 AM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com