# How do i put in "If any textbox is empty" code/block

**URL:** <https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833>\
**Category:** Questions about Thunkable X\
**Created:** [September 5, 2024, 11:48am UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833 "2024-09-05T11:48:52Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![aswinchandrasekharan](https://avatars.discourse-cdn.com/v4/letter/a/ebca7d/32.png) [@aswinchandrasekharan](https://community.thunkable.com/u/aswinchandrasekharan)\
**Post date:** [September 5, 2024, 11:48am UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/1 "2024-09-05T11:48:52Z")

</div>

Hi everyone. I am using thunkable for the first time. Was setting up a fuel log calculator. I have 3 to 4 textboxes where the quantities will be entered by the user and i wanted to put a if logic in case any of the textboxes was empty. I am not sure what specific blocks to use as i see the if/else logic but specifics how do i clip in to it that if any of the text boxes are left empty then turn the textbox border to red? Please help

---

<div class="post-metadata">

**Author:** ![ant\_1](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ant_1/32/183393_2.png) [@ant\_1](https://community.thunkable.com/u/ant_1)\
**Post date:** [September 5, 2024, 12:06pm UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/2 "2024-09-05T12:06:59Z")

</div>

hi there, welcome to the thunkable community,  
you can use the or logic block and fill in the spaces with label’s/text input’s text. hope this helps

---

<div class="post-metadata">

**Author:** ![ant\_1](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ant_1/32/183393_2.png) [@ant\_1](https://community.thunkable.com/u/ant_1)\
**Post date:** [September 5, 2024, 12:12pm UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/3 "2024-09-05T12:12:01Z")

</div>

something like this but connected with something

 ![Screen Shot 2024-09-05 at 4.11.21 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/4/1/41abd63449f8c29a773986441f324227e410d222.jpeg)

---

<div class="post-metadata">

**Author:** ![aswinchandrasekharan](https://avatars.discourse-cdn.com/v4/letter/a/ebca7d/32.png) [@aswinchandrasekharan](https://community.thunkable.com/u/aswinchandrasekharan)\
**Post date:** [September 5, 2024, 2:04pm UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/4 "2024-09-05T14:04:25Z")

</div>

Hi thank you for the suggestion. Ive just tried that. But i think there is some issue with it as it doesnt work.

---

<div class="post-metadata">

**Author:** ![aswinchandrasekharan](https://avatars.discourse-cdn.com/v4/letter/a/ebca7d/32.png) [@aswinchandrasekharan](https://community.thunkable.com/u/aswinchandrasekharan)\
**Post date:** [September 5, 2024, 2:06pm UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/5 "2024-09-05T14:06:24Z")

</div>

![Screenshot_20240905_220230_Chrome](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/0/b/0be9b560ce7e0ec409f41293261b0a7af1193ef1.jpeg)

---

<div class="post-metadata">

**Author:** ![aswinchandrasekharan](https://avatars.discourse-cdn.com/v4/letter/a/ebca7d/32.png) [@aswinchandrasekharan](https://community.thunkable.com/u/aswinchandrasekharan)\
**Post date:** [September 5, 2024, 2:08pm UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/6 "2024-09-05T14:08:16Z")

</div>

When i click the calculate sia button it should calculate and display those results if all fields have values in them.

---

<div class="post-metadata">

**Author:** ![ant\_1](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/ant_1/32/183393_2.png) [@ant\_1](https://community.thunkable.com/u/ant_1)\
**Post date:** [September 5, 2024, 3:08pm UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/7 "2024-09-05T15:08:33Z")

</div>

hi,  
you have to use the text component  
step one go to the text section of blocks

 ![Screen Shot 2024-09-05 at 7.06.06 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/b/0/b0abc652d34ca9ad5b7884d1f2ecfdbd3b1963ec.png)  
step two use this component colored in red  
 ![Screen Shot 2024-09-05 at 7.05.14 PM](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/d/a/da6c563fc626803df732f122b360fd1f6e28eb66.png)  
you have used the list one

---

<div class="post-metadata">

**Author:** ![aswinchandrasekharan](https://avatars.discourse-cdn.com/v4/letter/a/ebca7d/32.png) [@aswinchandrasekharan](https://community.thunkable.com/u/aswinchandrasekharan)\
**Post date:** [September 6, 2024, 2:49am UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/8 "2024-09-06T02:49:46Z")

</div>

Thank you that worked well. 🙏

---

<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:** [December 5, 2024, 2:50am UTC](https://community.thunkable.com/t/how-do-i-put-in-if-any-textbox-is-empty-code-block/3178833/9 "2024-12-05T02:50:25Z")

</div>

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