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 / Set default values for...
Power Apps
Unanswered

Set default values for check boxes on startup

(0) ShareShare
ReportReport
Posted on by 2

I have 10 check boxes but I only want 3 of them to be checked on startup of the app, however I'd like to uncheck or check them all from an 'All Check' box control. I understand that I can tie the default of each checkbox to my 'All Check' check box but this means that they are all checked on startup. I'm new to PowerApps and am coming from an MS Access background where you simply set controls in code. Thanks in advance for any help with this.

Categories:
I have the same question (0)
  • Verified answer
    madlad Profile Picture
    2,637 Moderator on at

    One thing you could do is create a collection of 10 items(one for each checkbox). 

     

    Perhaps start with something like:

     

    ClearCollect(
     Checkboxes, 
     [
     {ID:1, Checked: false}, 
     {ID:2, Checked: false}, 
     {ID:3, Checked: true}, 
     {ID:4, Checked: false}, 
     {ID:5, Checked: true}, 
     {ID:6, Checked: false}, 
     {ID:7, Checked: false}, 
     {ID:8, Checked: false}, 
     {ID:9, Checked: true}, 
     {ID:10, Checked: false}
     ]
    )

     

    Using this in the OnStart.(I just added 3 true values randomly, you can put them where you want)

     

    now you have a true false value for every checkbox, you can set each of the checkboxes defaults to be something like:

     

    LookUp(Checkboxes, ID = *Number*).Checked

     

     

    Then to reset all of them, you could do something like: 

     

    UpdateIf(Checkboxes, Checked = false, {Checked: true})

     

     

    I'm not certain if there's an easier way, but this will definitely work.

     

    Hope this helps!

  • DataFlowJoe Profile Picture
    2 on at

    That's brilliant, that's got me going again, thanks for taking the time to help me with this! Cheers @madlad 😉

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 327 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard