+ Reply to Thread
Results 1 to 3 of 3

Excel Advanced Filter copied a blank table over to a new sheet instead of data

  1. #1
    Registered User
    Join Date
    04-12-2021
    Location
    Singapore
    MS-Off Ver
    Office 365
    Posts
    8

    Question Excel Advanced Filter copied a blank table over to a new sheet instead of data

    Hi, I'm trying to create a macro that would allow me to filter a table with a dynamic range.

    Would like to be able to filter the data based on two criteria (Vent Size and Train); the data filtered can be either from one of the two or both at the same time.

    When I attempted to copy the data source from "Data" to "FilterData", the content isn't there. Instead, it was replaced with a blank table.

    I have a few named ranges; "Extract" refers to the table heading, which I would like my content to be copied over. "Criteria" is the criteria used for filtering.

    This is the code of the filter macro.

    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by Wilheim; 07-21-2021 at 12:22 AM. Reason: Clarity

  2. #2
    Forum Expert
    Join Date
    08-17-2007
    Location
    Poland
    Posts
    2,158

    Re: Excel Advanced Filter copied a blank table over to a new sheet instead of data

    In "Data" sheet, you have 5:152 rows hidden, which are blank. By this reference to Sheets("Data").Range("D4").CurrentRegion only returns one row - the header of the data range. And that's not enough to use an advanced filter.

    Artik

  3. #3
    Forum Expert nankw83's Avatar
    Join Date
    08-31-2015
    Location
    Kuwait
    MS-Off Ver
    365
    Posts
    1,709

    Re: Excel Advanced Filter copied a blank table over to a new sheet instead of data

    Hi Wilheim,

    Try the revised code below ...
    Please Login or Register  to view this content.
    If I was able to help, you can thank me by clicking the * Add Reputation under my user name

+ 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. For loop to past copied data at first blank row in another sheet
    By RaDoubleD in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 02-08-2018, 03:19 PM
  2. [SOLVED] Unable to filter data copied from pivot table
    By devawad in forum Excel Charting & Pivots
    Replies: 7
    Last Post: 05-10-2017, 12:55 AM
  3. [SOLVED] Advanced Filter - extract data to new sheet
    By schnautza in forum Excel Formulas & Functions
    Replies: 11
    Last Post: 01-28-2014, 02:43 PM
  4. Replies: 2
    Last Post: 11-19-2013, 04:25 PM
  5. Trying to filter data and display it on another sheet, however the data isn't fully copied
    By patrickvdveen88 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 10-12-2013, 12:54 PM
  6. advanced filter - data not being copied across
    By scubadiver007 in forum Excel General
    Replies: 10
    Last Post: 01-04-2012, 01:03 PM
  7. Search Table - Advanced Filter/Data Validation?
    By EmilyB in forum Excel General
    Replies: 1
    Last Post: 01-12-2011, 01:35 AM

Tags for this Thread

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