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 / Combining two statements
Power Apps
Unanswered

Combining two statements

(0) ShareShare
ReportReport
Posted on by 505

Using a Gallery how do I combine these two statements?

Items=Filter('Site Pages','Folder path' = "SitePages/Folder1/Folder2/")

Items=Choices('Site Pages'.Category)

Categories:
I have the same question (0)
  • mdevaney Profile Picture
    29,991 Moderator on at

    @send2mark 

    Like this...

    Choices(
     Filter(
     'Site Pages',
     'Folder path' = "SitePages/Folder1/Folder2/"
     ).Category
    )

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

     

  • send2mark Profile Picture
    505 on at

    It is returning the following error.

    The function 'Choices' has some invalid arguments. 

  • mdevaney Profile Picture
    29,991 Moderator on at

    @send2mark 

    I'm looking at your original question a little more closely and I'm finding the request to combine both statements does not make sense to me.  Why? CHOICES will always return the same values no matter what.  Filtering the result of CHOICES would have no effect.

    Are you trying to find the unique values in the categories column?  If yes, please try the DISTINCT function.

    Distinct(
     Filter(
     'Site Pages',
     'Folder path' = "SitePages/Folder1/Folder2/"
     ),
     Category.Value
    )

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

  • send2mark Profile Picture
    505 on at

    I am returning file properties from a library that is two folders deep and grouping them by a column name of Category. Maybe it would be easier to go a different route other than using the 'Folder path' option? Maybe one of the Categories could be called "NoGroup" and I could exclude it. What do you think?

     

    I should have added this in the first place. What I am doing is step 4 from this site.

     

     

  • mdevaney Profile Picture
    29,991 Moderator on at

    @send2mark

    Hello there Mark!  Perhaps the best approach here would be to post some sample data.  Then show me what the result should look like.  You can do this by copying and pasting data from Excel if necessary.

    The link to Yammer doesn't work for me but that's OK.  I'd prefer to hear you explain the problem anyway.

     

    ---
    Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

     

     

     

  • send2mark Profile Picture
    505 on at

    I'm sorry, I must have had that link on my clipboard without realizing it. Here is the correct link.

    https://www.c-sharpcorner.com/article/expand-and-collapse-view-using-nested-gallery-powerapps/

     

    In this image, Admin is a value in a column in a Site Pages library called Category. Those below it called Topic of Training TEMPLATE and Training Content are pages within that library at the root of the library. I do not want anything in the root.

     

    Item=Choices('Site Pages'.Category) is what displays my groups Admin, Analytics, Back-up and Retention, etc.

    screenshot of menu.png

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

#2
11manish Profile Picture

11manish 209 Super User 2026 Season 2

#3
MS.Ragavendar Profile Picture

MS.Ragavendar 150 Super User 2026 Season 2

Last 30 days Overall leaderboard