+ Reply to Thread
Results 1 to 3 of 3

VB to filter a table

  1. #1
    Registered User
    Join Date
    04-05-2016
    Location
    London
    MS-Off Ver
    2013
    Posts
    2

    VB to filter a table

    Hello - This is going to take some explaining so I hope you all catch what I'm getting at...

    On Sheet 1 I have a table. In this table I have several column headings and rows, etc. as in any table.
    An example is:

    ID | Name | Date 1 | Date 2 | Date 3

    Then, in my second sheet I want to be able to filter this table and only display rows which have values in one of the Date columns (As not all of them will).
    Is this possible? I imagine i will need to use VB, but thought I would check on here to see where everyone thinks I should start.

    Once that has been achieved I would like to order the filtered list with the earliest date, and show how many days have past since that date. But One step at a time...

    Thanks for reading!

  2. #2
    Administrator FDibbins's Avatar
    Join Date
    12-29-2011
    Location
    Duncansville, PA USA
    MS-Off Ver
    Excel 7/10/13/16/365 (PC ver 2310)
    Posts
    52,933

    Re: VB to filter a table

    Hi, welcome to the forum

    This can be done (at least part of it) with formulas, but I would suggest that you upload a small (clean) sample workbook (not a pic) of what you are working with, and what your expected outcome would look like.
    1. Use code tags for VBA. [code] Your Code [/code] (or use the # button)
    2. If your question is resolved, mark it SOLVED using the thread tools
    3. Click on the star if you think someone helped you

    Regards
    Ford

  3. #3
    Registered User
    Join Date
    04-05-2016
    Location
    London
    MS-Off Ver
    2013
    Posts
    2

    Re: VB to filter a table

    Of course - I have uploaded a simple one.
    Thanks for your reply.

    My initial idea at the moment is to have a button that selects the data in the table and creates a multidimensional array holding the rows that contain dates in 'Date 1'.
    This then sorts it, and populates the second table with the dates order.
    But i'm not sure if this is possible or if I am over complicating it?

    Thanks again!
    Attached Files Attached Files

+ 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. Replies: 0
    Last Post: 03-20-2015, 11:39 AM
  2. [SOLVED] Filter Table as i type in textbox1 but when erasing the text filter should be unfilter
    By HaroonSid in forum Excel Programming / VBA / Macros
    Replies: 4
    Last Post: 04-17-2014, 09:08 AM
  3. Replies: 1
    Last Post: 02-07-2014, 03:12 AM
  4. Replies: 1
    Last Post: 02-07-2014, 03:04 AM
  5. [SOLVED] How to set a 'Date Filter' on a field in the 'Report Filter' section of a Pivot Table?
    By Rhino_dance in forum Excel Charting & Pivots
    Replies: 7
    Last Post: 03-28-2013, 11:01 AM
  6. Change Pivot table Filter Based on Cell Value *Multiple Filter items* Possible?
    By Flydd in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-27-2012, 06:57 AM
  7. Place a number filter on a report filter in a pivot table
    By reuben.doetsch in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 11-01-2010, 12:41 PM

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