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 / RESET BUTTON NOT WORKI...
Power Apps
Answered

RESET BUTTON NOT WORKING WELL

(0) ShareShare
ReportReport
Posted on by 57

Hi community,

I have an issue and i tried many times and still not come up with the solution,

actually i have a Gallery with two checkboxes and i have a reset button to reset all checkboxes to false, 

with my code the reset button works but if you reset and check again the checkboxes, it will not work, but for the defaults values in checkbox, the reset button will work well and put all checkbox to false,

 

defaults value: means if you checked the box then next time if you open the powerapp the value will be retained in the checkbox.

 

here is my code:

reset button onselect: UpdateContext({ResetCheckbox:true});; If(ResetCheckbox=true; UpdateContext({T1:false}) || UpdateContext({T2:false}))

 

default for one checkbox: If(ResetCheckbox=true;false; T1||If(T2=true;false;ThisItem.YES="YES";true;false) || If(T2=true;false) || If(Toggle2.Value=true;false)|| If(Toggle1.Value=true;true) || If(T2=true;false)) || If(Toggle2.Value=true;false)

 

Privat2020_0-1667460832776.png

 

Categories:
I have the same question (0)
  • Community Power Platform Member Profile Picture
    on at

    Did you try to use the reset function ?

     

    Simply create a button and in "OnSelect" :

    Reset(YourCheckBoxFieldNameInTheTreeView);

     

  • Privat2020 Profile Picture
    57 on at

    Hi @Anonymous,

    Thanks for your feedback,

    i tried with no success! maybe i m doing it not in the right way,

    can you please let me know how to code it?

     

    Thanks.

     

  • Verified answer
    Community Power Platform Member Profile Picture
    on at

    Okey, I managed to do it ^-^

     

    So basically, click on your screen in the treeview. Inside "OnVisible"

    Set(VarReset, false)

    KitchenKirby_0-1667913903605.png

    Then, go to your button and put this code in the "OnSelect"

    Set(VarReset, true);
    Set(VarReset, false);

    KitchenKirby_1-1667914019114.png

    Then, finally, on both of your checkboxes in your gallery, in "Reset", simply write

    VarReset

    KitchenKirby_2-1667914095509.png

    For me, every time we click the button, all the checkboxes reset ^^ Have a nice day ~

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

#2
Michael E. Gernaey Profile Picture

Michael E. Gernaey 319 Super User 2025 Season 2

#3
Power Platform 1919 Profile Picture

Power Platform 1919 268

Last 30 days Overall leaderboard