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 multiple cri...
Power Apps
Answered

Filter by multiple criteria after Selecting a user from a previous gallery

(0) ShareShare
ReportReport
Posted on by 1,151

Hi

i want to filter calendar entries based on the name selected equal to calendar 'created by'

 

I have a gallery showing a list of specific names from a Sharepoint List.
The user selects a preferred person which then goes to a calendar view.
OnSelect  Navigate('BA SBA Calender',ScreenTransition.None, {selectedID: Gallery1.Selected.person_name})

this then navigates to the next screen which has the calendar on it.
I then use this on my 'CalendarEventsGallery2'

Filter('BA SBA Booking', Text('Start Time', DateTimeFormat.ShortDate) = Text(_dateSelected, DateTimeFormat.ShortDate) && Gallery1.Selected.person_name in 'Created By')
or if i use

Filter('BA SBA Booking', Text('Start Time', DateTimeFormat.ShortDate) = Text(_dateSelected, DateTimeFormat.ShortDate) && Gallery1.Selected.person_name in 'Created By')

 

But i get an error 'Cannot use record values in this context'

 

Gallery1 is the on the previous screen
Ideally i would like to do this by collection but don't really understand how to do that 😞
Thanks Gary

Categories:
I have the same question (0)
  • Verified answer
    gazzo1967 Profile Picture
    1,151 on at

    Hi All
    Just so it might help others.

    I found that the issue was that i was missing DisplayName in my filter options
    My previous filter was:
    Filter('BA SBA Booking', Text('Start Time', DateTimeFormat.ShortDate) = Text(_dateSelected, DateTimeFormat.ShortDate) && Gallery1.Selected.person_name in 'Created By')


    But when i added DisplayName to the second criteria values it works 🙂


    Filter('BA SBA Booking', Text('Start Time', DateTimeFormat.ShortDate) = Text(_dateSelected, DateTimeFormat.ShortDate ) && 'Created By'.DisplayName in Gallery1.Selected.person_name.DisplayName)

    Hopefully that will help someone later 🙂

    Gary

  • alrezac Profile Picture
    Microsoft Employee on at

    Hi,

     

    Looks like you were able to solve your issue here on your own. I wanted to just add in here a link to some documentation on look ups in Canvas Apps. Take a look if you would like to learn more.

     

    https://docs.microsoft.com/en-us/powerapps/maker/canvas-apps/working-with-references

     

    Regards,

     

    Alex

     

    -------

     

    Community Support Team _ Alex Rezac
    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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 329 Most Valuable Professional

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
Mohsin Ali Profile Picture

Mohsin Ali 179

Last 30 days Overall leaderboard