+ Reply to Thread
Results 1 to 3 of 3

Array VBA Filter

  1. #1
    Registered User
    Join Date
    01-17-2013
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    84

    Array VBA Filter

    Hi,
    I'm trying to build an array that will set the filter to search for blank dates and dates after two months. However, I cannot get it to work. Thanks for your help. Below is the code that I have for the filter.

    Please Login or Register  to view this content.

  2. #2
    Forum Contributor
    Join Date
    01-08-2016
    Location
    Cagayan De Oro City, Philippines
    MS-Off Ver
    2013
    Posts
    152

    Re: Array VBA Filter

    Hi ill mark our your problems here.................I had problems using the arrow sign so i just used text (lessthansign)

    Please Login or Register  to view this content.
    so first, you declared 'ft_Date' as a 'Date'......this is not an array..........and you dont really need to use an array here just a string

    Change it to this
    Please Login or Register  to view this content.

    Next
    you can put those next 2 lines into 1, just change it a little, lets also convert the last_two_month to a Long so the date becomes a number. why, because excel just stores dates as numbers so this will make sure we get something excel understands

    Please Login or Register  to view this content.
    Next
    Please Login or Register  to view this content.
    and that should do it, you can add those extra parts to the last code if you like but its not needed here
    Last edited by gbeats101; 04-11-2016 at 05:43 PM.

  3. #3
    Registered User
    Join Date
    01-17-2013
    Location
    Austin, TX
    MS-Off Ver
    Excel 2007
    Posts
    84

    Re: Array VBA Filter

    Thanks for your help. I was able to get it working with this.
    Please Login or Register  to view this content.

+ 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. [SOLVED] Filter Data with Array
    By jkj115 in forum Excel Programming / VBA / Macros
    Replies: 9
    Last Post: 03-19-2013, 04:22 PM
  2. Replies: 6
    Last Post: 05-26-2012, 04:56 AM
  3. Small if Array K- Use with filter
    By hiker100 in forum Excel Formulas & Functions
    Replies: 3
    Last Post: 09-17-2011, 09:41 AM
  4. Filter Array for ComboBox
    By Uziel in forum Excel Programming / VBA / Macros
    Replies: 5
    Last Post: 04-20-2010, 08:30 PM
  5. filter out the array
    By kaffal in forum Excel Programming / VBA / Macros
    Replies: 3
    Last Post: 03-29-2009, 02:06 PM
  6. Filter an Array
    By ShredDude in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 03-06-2008, 12:33 PM
  7. Use array to do advanced filter?
    By davegb in forum Excel Programming / VBA / Macros
    Replies: 2
    Last Post: 04-12-2005, 11:06 AM
  8. [SOLVED] Recordset Filter by Array
    By Kou Vang in forum Excel Programming / VBA / Macros
    Replies: 0
    Last Post: 02-01-2005, 01:06 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