# Access a control via block / Code

**URL:** <https://community.thunkable.com/t/access-a-control-via-block-code/2770090>\
**Category:** Questions about Thunkable X\
**Created:** [January 6, 2024, 4:52pm UTC](https://community.thunkable.com/t/access-a-control-via-block-code/2770090 "2024-01-06T16:52:50Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![spocreativ](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@spocreativ](https://community.thunkable.com/u/spocreativ)\
**Post date:** [January 6, 2024, 4:52pm UTC](https://community.thunkable.com/t/access-a-control-via-block-code/2770090/1 "2024-01-06T16:52:50Z")

</div>

Hello all

I have nothing found via Google search. Therefore, I assume it is not possible to access a control via code during runtime. Or is it possible?

What I looking for is to access, e.g., a label called label\_1 via name during runtime. I have 5 groups a five labels. So I enumerate thorough and access something like  
label\_X = background color black.  
I also assume it is not possible to get all children of a group (my five labels…)

Thanks for your feedback  
Regards  
Adrian

---

<div class="post-metadata">

**Author:** ![tatiang](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/tatiang/32/55482_2.png) [@tatiang](https://community.thunkable.com/u/tatiang)\
**Post date:** [January 6, 2024, 10:30pm UTC](https://community.thunkable.com/t/access-a-control-via-block-code/2770090/2 "2024-01-06T22:30:45Z")

</div>

This is possible with Any Component blocks: ["Any Component" Blocks - Thunkable Docs](https://docs.thunkable.com/blocks/advanced-app-features/any-component-blocks)

You can loop through “All labels in screen” for example and change a property for each within that loop.

I don’t have a great example of this but here’s something related that I created a while ago: [Thunkable](https://x.thunkable.com/copy/9241246623b74b4b6e39c94b210c67c0)

---

<div class="post-metadata">

**Author:** ![spocreativ](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@spocreativ](https://community.thunkable.com/u/spocreativ)\
**Post date:** [January 7, 2024, 11:25am UTC](https://community.thunkable.com/t/access-a-control-via-block-code/2770090/3 "2024-01-07T11:25:51Z")

</div>

Oh cool, thank you very much.  
I was not aware about this block. I will give it a try

---

<div class="post-metadata">

**Author:** ![spocreativ](https://avatars.discourse-cdn.com/v4/letter/s/50afbb/32.png) [@spocreativ](https://community.thunkable.com/u/spocreativ)\
**Post date:** [January 7, 2024, 11:31am UTC](https://community.thunkable.com/t/access-a-control-via-block-code/2770090/4 "2024-01-07T11:31:43Z")

</div>

Here is a test  
 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/3/5/350e40927943f8805396915a4e40824a1343bba2.png)  
and the result  
 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/6/8/681fd6685d25e2530b2033805aed5eb1b435a53d.png)

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/0/f/0f59f292712368bce16ff80133ae10de8a6f27e8.png) [@system](https://community.thunkable.com/u/system)\
**Post date:** [April 6, 2024, 11:32am UTC](https://community.thunkable.com/t/access-a-control-via-block-code/2770090/5 "2024-04-06T11:32:17Z")

</div>

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.
