web
You’re offline. This is a read only version of the page.
close
Skip to main content

Notifications

Announcements

Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Issue with filtering g...
Power Apps
Answered

Issue with filtering gallery by date range

(0) ShareShare
ReportReport
Posted on by 9

I have a gallery that I'm filtering by a few different queries and I see a weird issue every once in and while. 

 

It's a gallery within a gallery and when I first go to the screen the filter doesn't work properly but if I leave the screen and come back it then works properly. The first gallery acts like an accordion where the headers are the status, once clicked that section opens with the items with that status within the open section. 

 

First gallery 'Items' property:

 

Choices(Tasks.Status)

 

 

Inner gallery 'Items' property:

 

SortByColumns(
 Filter(
 Tasks,
 Status.Value = ThisItem.Value && ('Due Date' >= varStartDate && 'Due Date' <= varEndDate) && 'Created By'.Email = varUser.Email,
 StartsWith(
 Title,
 Search_5.Text
 ) || StartsWith(
 RelatedRequestTitle,
 Search_5.Text
 )
 ),
 "DueDate"
)

 

 

When I first go to the screen the item count is 0. If I go to a different screen and back to the first screen the items then show

2023-10-12_10-55-40.jpg2023-10-12_10-56-48.jpg

Categories:
I have the same question (0)
  • Verified answer
    BCBuizer Profile Picture
    22,510 Super User 2025 Season 2 on at

    Hi @t145h1b1 ,

     

    When navigating between screen, does the value of varStartDate and varEndDate change? 

  • Verified answer
    t145h1b1 Profile Picture
    9 on at

    Ugh, brain fart 😞 I was setting the date variables on a different screen's OnVisible prop. I've moved it to the app OnStart 

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Forum hierarchy changes are complete!

In our never-ending quest to improve we are simplifying the forum hierarchy…

Ajay Kumar Gannamaneni – Community Spotlight

We are honored to recognize Ajay Kumar Gannamaneni as our Community Spotlight for December…

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 386 Most Valuable Professional

#2
Kalathiya Profile Picture

Kalathiya 321

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 311 Super User 2025 Season 2

Last 30 days Overall leaderboard