+ Reply to Thread
Results 1 to 2 of 2

Macro code for advanced filtering

  1. #1
    Registered User
    Join Date
    04-03-2012
    Location
    Sri Lanka
    MS-Off Ver
    Excel 2013
    Posts
    26

    Macro code for advanced filtering

    Hi all,

    I wanted to automate some Advanced Filtering steps and I have recorded it in the macro recorder. (Please refer attached excel sheet)

    Current Scenario

    In this macro it takes data from "Masterdata" sheet (which is List Range in advanced filter) and Filter out data by criteria in "criteria" sheet (Criteria range in Advanced filter). the criteria range is dynamic and once I changed the criteria in the Criteria range the data in master data sheet filter out the data based on criteria selected in the criteria sheet.

    Drawback in the code

    But when I type a item in the criteria range which is not available in the "Masterdata" sheet it will take all the data in sheet (Which is obvious)


    Expected result

    when I type a item in the criteria range which is not available in the "Masterdata" sheet I don't want to show any data and the master data sheet should be blank.

    please help
    Attached Files Attached Files

  2. #2
    Forum Expert
    Join Date
    11-24-2013
    Location
    Paris, France
    MS-Off Ver
    Excel 2003 / 2010
    Posts
    9,831

    Re: Macro code for advanced filtering


    Hi,

    seems just some bad criteria ! I never met this issue …

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Similar Threads

  1. Recording advanced filtering macro
    By niukvba in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 09-02-2014, 03:48 AM
  2. Create automatic advanced filtering Code
    By netanel99 in forum Excel General
    Replies: 7
    Last Post: 06-03-2013, 03:00 AM
  3. Advanced filtering with multiple lines in VBA code
    By surfthenet in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-15-2012, 06:56 AM
  4. [SOLVED] Advanced Filtering by Date (or Macro) Help
    By Alexis in forum Excel Formulas & Functions
    Replies: 1
    Last Post: 03-08-2006, 01:15 PM
  5. [SOLVED] Macro to perform Advanced Filtering
    By Spencer Hutton in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 04-23-2005, 09:07 AM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1