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 / Change Combobox value ...
Power Apps
Answered

Change Combobox value based on gallery checkbox selection

(0) ShareShare
ReportReport
Posted on by 135

Hi All!

 

I've got a form that I created based on a sharepoint list.  I created a gallery with checkboxes (instead of a multi-selection combobox) inside that datacard.  

 

I have a status combobox in the same form that I want to change the values based on the selection in that gallery--but ONLY if a specific checkbox in that gallery is selected.  If the checkbox is not selected, leave the combobox alone.  

 

For the Default of the combobox I put in 

If(gallery1.Selected = "CheckboxName","Pending", Blank())

 

This is obviously not working, but I don't know what else to put in the "else" part of the If statement.  I could use some tips on the best way to do this.  

 

Categories:
  • RandyHayes Profile Picture
    76,299 Super User 2024 Season 1 on at

    @Smilee279 

    The Default property on a Combobox actually does nothing (not sure why it is there even).

    You will need to set the items in the DefaultSelectedItems (DSI) property of the control.

     

    Your DSI property needs to be a record or table (depending if you have multi-select enabled) that is identical to the Items property record schema.

    IF you are using a function such as Choices in the Items property, it will be a table with a single column called Value.  So, your DSI property would be:

        If(yourGalleryControl.Value, {Value: "Pending"})

     

    NOW...as to your Gallery checkbox - You need better criteria than Gallery1.Selected = "CheckboxName" as this is not going to be valid.  But, I am not sure of your scenario on the Gallery and how you are displaying that (i.e. the Items property).

     

    I hope this is helpful for you.

  • Verified answer
    Smilee279 Profile Picture
    135 on at

    @RandyHayes Thanks for this!  I ended up discussing this with a co-worker who is using Automate to do this.  I'm trying to create a badge access request system, and some of the areas (the checkboxes) require approvals, which require emails to trigger approvals.  My co-worker had created an automate flow to do this, and his flow might work better than me trying put everything into the app.  Along these lines:

    https://alextofan.com/2019/10/02/how-to-send-approval-requests-to-groups-in-microsoft-flow/ 

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

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 382 Super User 2026 Season 2

#2
Mohsin Ali Profile Picture

Mohsin Ali 329

#3
WarrenBelz Profile Picture

WarrenBelz 187 Most Valuable Professional

Last 30 days Overall leaderboard