Skip to main content

Notifications

Community site session details

Community site session details

Session Id : z2qZ1uBn8A+tscJwQPwVmt
Power Apps - Building Power Apps
Unanswered

How Can I Select only one item on a Gallery powerApps

Like (0) ShareShare
ReportReport
Posted on 4 Nov 2022 10:55:25 by

Hi,

 

I have a problem and I don't know how to solve it. I have a gallery that contains many incident reports. To filter these reports, I use several filters and one of these is a checkbox. To set them horizontally, I have created a gallery containing this checkbox with the three options. I would like to choose only one option but as I am using a gallery it allows me to choose more than one option. How can I select this?

 

Thank you very much and best regards,

 

Josu.

 

JosuIaki_0-1667558991123.png

JosuIaki_1-1667559025019.png

 

  • Cedric0404 Profile Picture
    116 on 16 Jul 2024 at 11:08:34
    Re: How Can I Select only one item on a Gallery powerApps

    Hello, your solution works really good, but I have one issue.

     

    I'm using an Textinput to search for entries in the gallery. Im using Filter(test;Startswith(textinput)) on the gallerys item property. 

     

    But as soon as im typing something in the textinput it automatically ticks one checkbox. 

     

     

    Thanks for your help!

  • Community Power Platform Member Profile Picture
    on 15 Nov 2022 at 11:49:01
    Re: How Can I Select only one item on a Gallery powerApps

    Hi Warren,

     

    Sorry for that, I dont that info can be helpful.. Okay I will try.

     

    Thank you .

  • WarrenBelz Profile Picture
    146,702 Most Valuable Professional on 15 Nov 2022 at 09:05:25
    Re: How Can I Select only one item on a Gallery powerApps

    Hi @Anonymous ,

    It would have been useful to know that you are also populating a collection OnCheck (and removing the item OnUncheck) Your problem will be with your Default as this will refer to a collection field and the pattern I posted will not work there.

     

  • Community Power Platform Member Profile Picture
    on 15 Nov 2022 at 07:14:03
    Re: How Can I Select only one item on a Gallery powerApps

    For the checkbox to be delegable, it is linked to a dropdown as shown in this video.
    https://www.youtube.com/watch?v=5dSk5iOgT68&ab_channel=RezaDorrani

     

    I think this may be the reason why your method is not working. If you want, you can try with the configuration that has the gallery with the checkbox in the video.

     

    Thank you very much for all the support, it is really appreciated.

  • WarrenBelz Profile Picture
    146,702 Most Valuable Professional on 14 Nov 2022 at 20:29:07
    Re: How Can I Select only one item on a Gallery powerApps

    @Anonymous  ,

    What does not work - I have tested it here with the expected results - I assume the check box is in a Gallery

    Only1Check.gif

    Do you have these 3 settings ?

    ChkText.png

    ChkDefault.pngChkOnSelect.png

     

     

  • Community Power Platform Member Profile Picture
    on 14 Nov 2022 at 11:02:26
    Re: How Can I Select only one item on a Gallery powerApps

    This doesnt work... But thank you for the support

  • WarrenBelz Profile Picture
    146,702 Most Valuable Professional on 14 Nov 2022 at 10:50:04
    Re: How Can I Select only one item on a Gallery powerApps

    @Anonymous 

    Put the code on the OnSelect instead of the OnCheck it you want to also uncheck the box. I just tested again and it works as expected.

     

    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.

    Visit my blog Practical Power Apps

  • Community Power Platform Member Profile Picture
    on 14 Nov 2022 at 08:12:16
    Re: How Can I Select only one item on a Gallery powerApps

    This image is when you open the screen (without select):

     

    JosuIaki_0-1668413284383.png

    This capture is when you select one option (work fine):

    JosuIaki_1-1668413387478.png

    But when we change the textbox(option), doestn work fine... 

    JosuIaki_2-1668413520834.png

     

     

  • Community Power Platform Member Profile Picture
    on 14 Nov 2022 at 08:06:25
    Re: How Can I Select only one item on a Gallery powerApps

    I think that can be because when you "OnUncheck" the checkbox, the value cannot have a blank value. 

  • WarrenBelz Profile Picture
    146,702 Most Valuable Professional on 14 Nov 2022 at 07:58:01
    Re: How Can I Select only one item on a Gallery powerApps

    @Anonymous ,

    What exactly does not work (see my video working) ?

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

Understanding Microsoft Agents - Introductory Session

Confused about how agents work across the Microsoft ecosystem? Register today!

Markus Franz – Community Spotlight

We are honored to recognize Markus Franz as our April 2025 Community…

Kudos to the March Top 10 Community Stars!

Thanks for all your good work in the Community!

Leaderboard

#1
WarrenBelz Profile Picture

WarrenBelz 146,702 Most Valuable Professional

#2
RandyHayes Profile Picture

RandyHayes 76,287 Super User 2024 Season 1

#3
Pstork1 Profile Picture

Pstork1 66,015 Most Valuable Professional

Leaderboard
Loading started