+ Reply to Thread
Results 1 to 13 of 13

Filter specific table column in excel with two criteria in another sheet

  1. #1
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Question Filter specific table column in excel with two criteria in another sheet

    HOW CAN we filter table for two criteria and copy the result in another sheet?

    for example wwe have student data table and there is more than 10 columns such as name,student id,phone,address,class,age,birthday, .....

    now we want have just student name , birthday and age for students that their age is 15 in another sheet

    how can we do this?

    i need it for dashboard ,

    i can write "for loop" to find the result but i look for better way

  2. #2
    Valued Forum Contributor
    Join Date
    06-29-2014
    Location
    Australia
    MS-Off Ver
    MSO 365
    Posts
    1,098

    Re: Filter specific table column in excel with two criteria in another sheet

    Hello Alinaim,

    Could you please upload a sample of your workbook so that we can better understand your issue. Instructions on how to upload a sample are described in the gold coloured banner at the top of this page.

    Thank you Alinaim.

    Cheerio,
    vcoolio.

  3. #3
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    Here is sample file for the question.
    Attached Files Attached Files

  4. #4
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    Hello dear
    thanks for your answer
    i think this file will explain the problem

  5. #5
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: Filter specific table column in excel with two criteria in another sheet

    HOW CAN we filter table for two criteria and copy the result in another sheet?
    Please Login or Register  to view this content.
    Attached Files Attached Files
    Last edited by sintek; 11-12-2021 at 02:31 AM.
    Good Luck
    I don't presume to know what I am doing, however, just like you, I too started somewhere...
    One-day, One-problem at a time!!!
    If you feel I have helped, please click on the star to left of post [Add Reputation]
    Also....add a comment if you like!!!!
    And remember...Mark Thread as Solved.
    Excel Forum Rocks!!!

  6. #6
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    Thanks...
    The code works great

    but

    would you explain the code?
    I dont understand the how does it works?

    I thought there should be simpler way to do this like using advance filter or object list

  7. #7
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    and can we solve the problem without evaluate
    and solve it wit vba tools not refer it to excel

  8. #8
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: Filter specific table column in excel with two criteria in another sheet

    Code uses Evaluate method to filter out criteria and slice specific columns to extract...
    see here

  9. #9
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: Filter specific table column in excel with two criteria in another sheet

    Another option...
    Please Login or Register  to view this content.

  10. #10
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    thanks a lot

    and adding to your code
    we can use
    table.ListColumns("*****").Index
    to make it more dynamic

  11. #11
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    but a question left
    would you explain about .parent in this cod?
    i have not seen this cod before

  12. #12
    Forum Expert sintek's Avatar
    Join Date
    12-04-2015
    Location
    Cape Town
    MS-Off Ver
    2013 | 2016 | 2019
    Posts
    13,210

    Re: Filter specific table column in excel with two criteria in another sheet

    Please Login or Register  to view this content.
    In the above With statement...
    .Parent refers to the sheet object

  13. #13
    Registered User
    Join Date
    04-01-2017
    Location
    iran
    MS-Off Ver
    2016
    Posts
    30

    Re: Filter specific table column in excel with two criteria in another sheet

    thanks, question completely solved

+ 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. Filter on specific column in pivot table
    By banpreet in forum Excel Charting & Pivots
    Replies: 3
    Last Post: 06-03-2020, 12:39 PM
  2. Filter on specific column in pivot table
    By banpreet in forum Excel Charting & Pivots
    Replies: 0
    Last Post: 06-03-2020, 09:39 AM
  3. [SOLVED] Copy specific column data from one sheet to another sheet using Certain filter Criteria
    By xlhelp7 in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 02-02-2017, 12:09 AM
  4. [SOLVED] Delete not meeting criteria, criteria in column another sheet (Filter)
    By marreco in forum Excel Programming / VBA / Macros
    Replies: 6
    Last Post: 10-10-2016, 07:32 AM
  5. Filter On or Off for specific Column in table
    By BG1983 in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 09-13-2016, 05:05 PM
  6. Pivot table: Filter column with multiple criteria
    By tonelot in forum Excel General
    Replies: 8
    Last Post: 06-15-2015, 08:38 AM
  7. Replies: 1
    Last Post: 12-12-2014, 06:46 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