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 / Filtering on PowerApp ...
Power Apps
Unanswered

Filtering on PowerApp Selection

(0) ShareShare
ReportReport
Posted on by 11

Hi all, 

 

Trying to get a desk booking app working using April's template.  Need to insert a filter to only show desks according to a building and whether they have already been booked. 

 

Photo below shows the part that I have inserted that doesnt work.  Office_location is a column in SP. Bld is a variable set from the previous screen where a user selects the office location (building photo)

 

So what I am wanting is for the user to select the Building location, this sets the BLD value which then moves to the next screen .  Next screen is the desk select screen which should only return desks that have NOT already been booked (as per SP List) and also also only relate to the value set against the location (from 1 to 5) from the previous screen.  

 

I am going around in circles on this now so any help would be gratefully accepted . 

 

Thanks

 

 

Build.JPG

 

Filter showing the part that doesn't work.Filter showing the part that doesn't work.

Categories:
I have the same question (0)
  • BrianS Profile Picture
    2,407 Super User 2024 Season 1 on at

    Have you tried to Filter just on the Building number to see if that works by itself? It is often easier to build these filters up piece by piece. Could be a Value vs Text issue? 

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @stevec1 

    I believe you might be wanting your formula to be the following instead:

    Filter(
     Desks,
     !(Title in Filter('Desk Reservations', 
     (CheckOutFrom >= startsTime && CheckOutTo <= endTime) ||
     (CheckOutFrom <= endTime && CheckOutTo >= endTime)
     ).DeskText
     ) &&
     Office_Location = Bld
    )
     

     

    I hope this is helpful for you.

  • stevec1 Profile Picture
    11 on at

    Hi Brian - yes, I can get the filter working just on just the Office_Location (see below)

     

    Filter(
    Desks,
    Office_Location = [@Bld]
    )

     

    Both filters work independently but trying to add them together is causing me issues.  

  • stevec1 Profile Picture
    11 on at

    Hi Randy - thanks for the suggestion - that didn't work either.  The main part of the filter is one I got from April's template on PowerApps and works fine on its own - I just wanted to add in a building selector screen first to narrow down the list of desks available.   

     

    @BrianS  - went back through and edited my SP column to be a text column rather than number - that has got me further so going to continue down that path - fingers crossed.

     

    Appreciate the advice guys 🙂  

     

     

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @stevec1 

    Can you elaborate more on what doesn't work?  The filter should do exactly what is intended based on my understanding of your scenario - so perhaps it is your scenario that I am not understanding.

     

     

  • stevec1 Profile Picture
    11 on at

    Hey Randy - I have got it working now but in essence, I have edited a template that April provided so that staff can use an app to reserve a hot desk. Hot Desk list in SharePoint with the 500 desks that we have across 5 office locations.  Original template didnt factor in location but did look at another SP list called desk reservations and only returned available desks based on whether that desk already showed up in the reservation list. 

     

    I added a new screen in for user to select Office Location and then the result only showed desks that did NOT appear in the Desk Reservations List for that location. 

     

    Hope that explains it further but just glad to have got past this stage. 

     

    Cheers

     

  • RandyHayes Profile Picture
    76,297 Super User 2024 Season 1 on at

    @stevec1 

    Yes, I am not familiar with April or the desk reservation template, but it sounds like you have worked your way through the issue at this point...keep moving forward!!

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 343 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 272

Last 30 days Overall leaderboard