Filter for dates after today

Solved
Dakine -  
 Dakine -
Hello,
I want to create a macro that will allow me to filter my data in Excel.

I have a column with dates and I want to filter my file to only show the rows of records where the date is after today.

Configuration: Windows XP / Internet Explorer 8.0

3 réponses

reyny
 
I propose the following formula:
If the date line is in F:F then position yourself, for example, in G1 and type the following formula.

=IF(F1="";"";IF(F1>TODAY();"";F1))

You just need to hide column F:F or another one...
0
michel_m Posted messages 18903 Registration date   Status Contributeur Last intervention   3 320
 
Hello,

If you want a macro, here's a little demo:
https://www.cjoint.com/?3HFlFpZ0Unz

Sub filter_after_today() Range("A1").AutoFilter field:=2, Criteria1:=">" & CDbl(Date) End Sub


Michel
0
Dakine
 
Thank you, it works perfectly!
0