# Shouldn't this code disable all the buttons?

**URL:** https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318
**Category:** Questions about Thunkable X
**Tags:** button
**Created:** [September 25, 2020, 3:52am UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318 "2020-09-25T03:52:36Z")
**Posts on this page:** 7
**Page:** 1

<div class="post-metadata">

### Author: ![sleon003x2rq](https://avatars.discourse-cdn.com/v4/letter/s/ecb155/32.png) [@sleon003x2rq](https://community.thunkable.com/u/sleon003x2rq)
#### Post date: [September 25, 2020, 3:52am UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/1 "2020-09-25T03:52:36Z")

</div>

quick question

I have never used the all button block before, shouldn’t the following disable all the buttons in the referenced column?

it doesn’t appear to be working for me

![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/a/0/a08638bbb79c1975ebd13e266b607c57840aef50.png)

---

<div class="post-metadata">

### Author: ![tchind](https://avatars.discourse-cdn.com/v4/letter/t/ebca7d/32.png) [@tchind](https://community.thunkable.com/u/tchind)
#### Post date: [September 25, 2020, 4:10am UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/2 "2020-09-25T04:10:26Z")

</div>

set disabled to true it is to false

---

<div class="post-metadata">

### Author: ![eko.devs.apploroceo](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/eko.devs.apploroceo/32/93147_2.png) [@eko.devs.apploroceo](https://community.thunkable.com/u/eko.devs.apploroceo)
#### Post date: [September 25, 2020, 5:47am UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/3 "2020-09-25T05:47:00Z")

</div>

yes he is right

---

<div class="post-metadata">

### Author: ![actech](https://avatars.discourse-cdn.com/v4/letter/a/3d9bf3/32.png) [@actech](https://community.thunkable.com/u/actech)
#### Post date: [September 25, 2020, 7:19am UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/4 "2020-09-25T07:19:31Z")

</div>

Your code doesn’t work because you don’t use blocks correctly. [all buttons in Column] returns a list of buttons that does not have the Disabled property. You need to create a loop through the list of buttons, and set Disabled = true for each element in this list.

foreach Item in [all buttons in Column] {  
Item.Disabled = true  
}

---

<div class="post-metadata">

### Author: ![roumak-coder](https://avatars.discourse-cdn.com/v4/letter/r/b38774/32.png) [@roumak-coder](https://community.thunkable.com/u/roumak-coder)
#### Post date: [September 25, 2020, 8:03am UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/5 "2020-09-25T08:03:00Z")

</div>

![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/e/4/e4328df2d05b3a48ccffbc3cb675843385e42eff.png)  
I think this code should work

---

<div class="post-metadata">

### Author: ![sleon003x2rq](https://avatars.discourse-cdn.com/v4/letter/s/ecb155/32.png) [@sleon003x2rq](https://community.thunkable.com/u/sleon003x2rq)
#### Post date: [September 25, 2020, 2:08pm UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/6 "2020-09-25T14:08:42Z")

</div>

thanks all for the replies

---

<div class="post-metadata">

### Author: ![ioannis](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ioannis/32/146956_2.png) [@ioannis](https://community.thunkable.com/u/ioannis)
#### Post date: [November 8, 2024, 12:23pm UTC](https://community.thunkable.com/t/shouldnt-this-code-disable-all-the-buttons/847318/7 "2024-11-08T12:23:45Z")

</div>


