Showing results for 
Search instead for 
Did you mean: 
Helper I
Helper I

Gallery Filter to display items not modified within timeframe

I have a standard formula filtering my galley but need to modify it to include only items that have not been modified in the last 14 days.


SortByColumns(Filter(Search(Issues, "Active", "Status"),(TextSearchBox1_3.Text in Issue)), "Modified", If(SortDescending3, Ascending, Descending))


Any help would be greatly appreciated! 

Power Apps
Power Apps

You can use the DateAdd function to compare against the Modified column in your data source, something along the lines of the expression below:

        Search(Issues, "Active", "Status"),
        TextSearchBox1_3.Text in Issue,
        Modified < DateAdd(Today(), -14, Days)),
    If(SortDescending3, Ascending, Descending))

Thanks for the reply @CarlosFigueira 


Two issues though:


1. The formula you have suggested does not return any results for the Gallery and has the yellow errors.


However a simplified version does work and the gallery populates:


Filter(Issues,Modified > DateAdd(Today(),-14,Days))


2. Your suggested formula returns items that have been modified in the last 14 days, I need the opposite - Items that have not been modified in the last 14.


Cheers. Smiley Very Happy

Helpful resources

Super User 2 - 2022 Congratulations 768x460.png

Welcome Super Users

The Super User program for 2022 - Season 2 has kicked off!

Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Users online (4,899)