+ Reply to Thread
Results 1 to 3 of 3

VBA : Filter data using today's date

  1. #1
    Registered User
    Join Date
    07-02-2014
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    2

    VBA : Filter data using today's date

    Hello,

    I would like to fileter data by a date column and 2 limit parameters.
    Basically, I want to select the line for which the date in column G is between today - nb1 (nb1 number of days) and today - nb2 (nb2 number of days).

    So I use the following code to filter it :

    Please Login or Register  to view this content.
    The problem is, no line is selected.
    Then I check manually the filter, I can see the two limit dates and when I apply the filter again (without changing dates), the line appear.
    I just do not understand why it does not work with the macro in the first place.

    Would any of you have a solution?

    Thanks in advance!
    Louis

  2. #2
    Valued Forum Contributor
    Join Date
    09-21-2011
    Location
    Birmingham UK
    MS-Off Ver
    Excel 2003/7/10
    Posts
    2,188

    Re: VBA : Filter data using today's date

    Can you send the book?
    Hope this helps

    Sometimes its best to start at the beginning and learn VBA & Excel.

    Please dont ask me to do your work for you, I learnt from Reading books, Recording, F1 and Google and like having all of this knowledge in my head for the next time i wish to do it, or wish to tweak it.
    Available for remote consultancy work PM me

  3. #3
    Registered User
    Join Date
    07-02-2014
    Location
    London, England
    MS-Off Ver
    2010
    Posts
    2

    Re: VBA : Filter data using today's date

    Here it is,

    Book2.xlsm
    Thanks,
    Louis

+ 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 today's date forward
    By Marcus Gee in forum Excel Programming / VBA / Macros
    Replies: 8
    Last Post: 11-13-2018, 07:36 AM
  2. [SOLVED] Code to auto filter three month segments of data from today's date
    By gryffin13 in forum Excel Programming / VBA / Macros
    Replies: 1
    Last Post: 07-17-2012, 04:51 PM
  3. Filter based on today's date and send mail in outlook
    By kandanuru in forum Excel General
    Replies: 0
    Last Post: 06-15-2012, 04:59 AM
  4. [SOLVED] filter by today's date
    By KAPearson in forum Excel Programming / VBA / Macros
    Replies: 20
    Last Post: 05-28-2012, 02:19 PM
  5. [SOLVED] Way to have VB code to filter on entries that have cell with today's date?
    By StargateFan in forum Excel Programming / VBA / Macros
    Replies: 7
    Last Post: 05-17-2005, 09:06 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