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

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Filter by Date Range a...
Power Apps
Unanswered

Filter by Date Range and Multi Selected ListBox or ComboBox in a DataTable

(0) ShareShare
ReportReport
Posted on by

I have a datatable created from a Sharepoint List that has a Date Column and several Text, number and currency columns. I have two date picker controls and a ListBox Control applied to the app screen. 

 

My ListBox Items Property is:  

Choices('DataSetName'.Store)

 

My datatable Items Property is: 

Sort(Filter('DataSetName',Date>=DatePicker1.SelectedDate,Date<=DatePicker2.SelectedDate,Store.Value=ListBox1.SelectedText.Value),Date,Descending)

 

The Store property has 5 unique values in it.

 

I need to display all of the columns from each record in the datatable based upon the date range and all of the values selected in the ListBox. (This is a daily sales tool with columns that sum currency and customer interactions for a retail sales biz)

 

So if i select 2 Stores and a Date range I currenlty only get the last recordset that was selected from the listbox to display in the datatable. 

 

I have been banging my head against the wall on this trying 'ForAll', "Concat', 'Collect' and more but i am still too new at this to get the order, syntax and placement right.

 

Any help would be appreciated!

 

Categories:
I have the same question (0)
  • WarrenBelz Profile Picture
    156,277 Most Valuable Professional on at

    Hi @ElvisPSherman ,

    You are correct in that this is not simple with a many-to-one filter (I assume the Store field is not multi-select or this would be different again as many-to-many) - try this

    With(
     {
     wDates:
     Filter(
     'DataSetName',
     Date >= DatePicker1.SelectedDate &&
     Date <= DatePicker2.SelectedDate
     )
     },
     Ungroup(
     ForAll(
     ListBox1.SelectedItems As aList,
     Filter(
     wDates,
     Store.Value = aList.Value
     )
     ),
     "Value"
     )
    )

     

    Please click Accept as solution if my post helped you solve your issue. This will help others find it more readily. It also closes the item. If the content was useful in other ways, please consider giving it Thumbs Up.

    MVP (Business Applications)   Visit my blog Practical Power Apps

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

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
WarrenBelz Profile Picture

WarrenBelz 400 Most Valuable Professional

#2
11manish Profile Picture

11manish 141 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 109 Super User 2026 Season 2

Last 30 days Overall leaderboard