cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Doors1980 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! 

2 REPLIES 2
Power Apps
Power Apps

Re: Gallery Filter to display items not modified within timeframe

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

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

Re: Gallery Filter to display items not modified within timeframe

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

Announcements
secondImage

Community User Group Member Badges

FIll out a quick form to claim your community user group member badge today!

firstImage

New Ranks and Rank Icons released on April 21!

The time has come: We are finally able to share more details on the brand-new ranks coming to the Power Apps Community!

Top Solution Authors
Top Kudoed Authors
Users online (7,560)