cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
New Member

Disable checkbox on button click

Hello,

 

I have 4 checkboxes and 1 button, it's a screen with test, so i don't want user to change his marks in any checkbox more than once. 

So how can I disable checkboxes after pressing a button?

 

I tried to write in a checkbox1 displaymode this: 

If(Button3_19.Pressed,DisplayMode.Disabled, DisplayMode.Edit)

But it disables checkbox only while I keep the button pressed. 😥

1 ACCEPTED SOLUTION

Accepted Solutions
Super User III
Super User III

OnCheck of the Checkbox, create a variable;
UpdateContext (DisabledCheck,true)

 

Or use a set variable;
Set(DisabledCheck,true)

 

Then in the Displaymode;
If(DisabledCheck,DisplayMode.Disabled, DisplayMode.Edit)

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

View solution in original post

2 REPLIES 2
Super User III
Super User III

OnCheck of the Checkbox, create a variable;
UpdateContext (DisabledCheck,true)

 

Or use a set variable;
Set(DisabledCheck,true)

 

Then in the Displaymode;
If(DisabledCheck,DisplayMode.Disabled, DisplayMode.Edit)

------------

If you like this post, give a Thumbs up. Where it solved your request, Mark it as a Solution to enable other users find it.

View solution in original post

@eka24 Thanks a lot, it works even better than I suggested 😊

Helpful resources

Announcements
News & Announcements

Community Blog

Stay up tp date on the latest blogs and activities in the community News & Announcements.

Power Apps Community Call

Power Apps Community Call- January

Mark your calendars and join us for the next Power Apps Community Call on January 20th, 8a PST

PP Bootcamp Carousel

Global Power Platform Bootcamp

Dive into the Power Platform stack with hands-on sessions and labs, virtually delivered to you by experts and community leaders.

secondImage

Power Platform Community Conference On Demand

Watch Nick Doelman's session from the 2020 Power Platform Community Conference on demand!

Top Solution Authors
Top Kudoed Authors
Users online (4,039)