# Help needed with changing list viewer to different variables

**URL:** https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166
**Category:** Questions about Thunkable X
**Created:** [October 26, 2021, 3:44am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166 "2021-10-26T03:44:05Z")
**Posts on this page:** 15
**Page:** 1

<div class="post-metadata">

### Author: ![jakeheron](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jakeheron/32/116818_2.png) [@jakeheron](https://community.thunkable.com/u/jakeheron)
#### Post date: [October 26, 2021, 3:44am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/1 "2021-10-26T03:44:05Z")

</div>

@muneer @tatiang  
Hi, I hope you are having a good day.

I have a homework assignments screen and what I would want to occur is when the user clicks on the ‘subject’ field, the list viewer displays their subjects which they have previously entered so that they can pick a subject for the assignments. I have designed the code as follows:

 ![Screen Shot 2564-10-26 at 10.50.24](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/4/7/47acbefa420e7bf653d5d151ee0c8bfccea5cfdd.png)

![Screen Shot 2564-10-26 at 10.40.54](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/b/4/b49d3909774845550f9cd7beb4562d21061178fe.png)

When the subject field is clicked the first time, it works fine, however, it does not work again once the assignment as been added. I’m not sure why this is occurring, any help would be much appreciated.

Here is a link to the project:

[https://x.thunkable.com/copy/0d2c27257406f9e4ec564fce6ffe4903](https://x.thunkable.com/copy/0d2c27257406f9e4ec564fce6ffe4903)

Note: when you live test the app, you will first have to enter in some subjects.

Thanks!

---

<div class="post-metadata">

### Author: ![rishabh\_jain](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/rishabh_jain/32/125953_2.png) [@rishabh\_jain](https://community.thunkable.com/u/rishabh_jain)
#### Post date: [October 26, 2021, 6:18am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/2 "2021-10-26T06:18:30Z")

</div>

the UI IS GOOD

---

<div class="post-metadata">

### Author: ![kartik14](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/kartik14/32/44782_2.png) [@kartik14](https://community.thunkable.com/u/kartik14)
#### Post date: [October 26, 2021, 6:31am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/3 "2021-10-26T06:31:21Z")

</div>

Hi, @jakeheron! I think getting a new list-viewer for selecting stored subjects would simplify the process for you

If you create a new listviewer for displaying stored subjects, you would not need to check `if list = subjects list` when an item click occurs in the `assignments` list; You can add the code for `subjects list - item click` into it’s own block.

You can hide/show the list whenever you like, for example after selecting the subject, hide the subject list and show the assignments list.

Let me know if this works for you. Cheers!

* * *

_Also I had a look into your project, and I must say too - you have designed a very clean and beautiful UI for your app. Congrats!_ 😊

---

<div class="post-metadata">

### Author: ![jakeheron](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jakeheron/32/116818_2.png) [@jakeheron](https://community.thunkable.com/u/jakeheron)
#### Post date: [October 26, 2021, 7:00am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/4 "2021-10-26T07:00:48Z")

</div>

Hi @kartik14 ,

Thank you very much for the kind words. I have added your suggestion and it is working, however, there is a still a problem with selecting the text input field. When the input is clicked the first time, everything works fine, however, if you selected it again, nothing happens. Any reason why this may be occurring.

Thanks!

---

<div class="post-metadata">

### Author: ![kartik14](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/kartik14/32/44782_2.png) [@kartik14](https://community.thunkable.com/u/kartik14)
#### Post date: [October 26, 2021, 7:11am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/5 "2021-10-26T07:11:10Z")

</div>

Hi! Please tell me if I am right - you want to show the users your subjects list whenever he/she clicks on the ‘Subject (Type here)’ field.

If I got it right, try this -  
 ![image](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/c/6/c67e1da5f7a5d3dd0c2997e5e34e8816c6c300c6.png)

Let me know if this works. Cheers!

---

<div class="post-metadata">

### Author: ![jakeheron](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jakeheron/32/116818_2.png) [@jakeheron](https://community.thunkable.com/u/jakeheron)
#### Post date: [October 26, 2021, 8:44am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/6 "2021-10-26T08:44:51Z")

</div>

@kartik14

Yes it is working, however, as previously stated, it does not work the second time. In other words, once the assignment has been added, if the user clicks on subject again, the subject list will not be shown. You can test it if you like:

[https://x.thunkable.com/copy/7b83baa0e20a705f35f87bf6ffa6cf99](https://x.thunkable.com/copy/7b83baa0e20a705f35f87bf6ffa6cf99)

(press demo on data entry to automatically populate fields)

---

<div class="post-metadata">

### Author: ![jakeheron](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jakeheron/32/116818_2.png) [@jakeheron](https://community.thunkable.com/u/jakeheron)
#### Post date: [October 26, 2021, 11:08am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/7 "2021-10-26T11:08:34Z")

</div>

@muneer could you possibly help with this? Thanks.

---

<div class="post-metadata">

### Author: ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)
#### Post date: [October 26, 2021, 4:11pm UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/8 "2021-10-26T16:11:04Z")

</div>

I tried the link but I only get empty screen.

I was able to re-mix your project and use the **DEMO** button as suggested but once I select a subject from the timetable, the app crashes and never reach to the homework screen.

---

<div class="post-metadata">

### Author: ![kartik14](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/kartik14/32/44782_2.png) [@kartik14](https://community.thunkable.com/u/kartik14)
#### Post date: [October 27, 2021, 4:07am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/9 "2021-10-27T04:07:04Z")

</div>

Hi, @jakeheron! I ran some tests on your given project, and it seems that there’s a bug in the textInput.click block - It does not consider more than one clicks. I hope the Thunkable team will fix this.

Meanwhile, you can try this workaround - since you are not letting the user actually enter text into the subject box, why not make it a button? _(subject input in the below code represents a button)_

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

Now in the Designer area, you can customize the borderColor, fontSize, etc. of the subject input button to make it look similar to it’s surrounding components (`dateInput` / `textInput`).

Let me know if this helps. Cheers!

---

<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: [October 27, 2021, 5:06am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/10 "2021-10-27T05:06:04Z")

</div>

@kartik14 @jakeheron I’ve reported the bug you discovered here:

> <https://github.com/thunkable/thunkable-issues/issues/1043>
>
> \### Platform
> Drag and Drop UI - web
> 
> \### Steps to Reproduce
> 1. Add a text in…put component to a screen
> 2. Set up a click detection for the text input and keep track of number of clicks
> 3. The first click registers and increases the count. The next click(s) do not.
> 
> (See project link and screenshot below)
> 
> \### Expected Behavior
> When unfocusing (clicking off of) the text input and then clicking it again, the count would increase.
> 
> \### Actual Behavior
> The count stops at 1.
> 
> \### Project Link
> https://x.thunkable.com/copy/cba58dd098045450586125f1ab5c6d2b
> 
> \###Community Link
> https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/9
> 
> \`\`\`
> STACK TRACE AND/OR SCREENSHOTS
> \`\`\`
> 
> !\[139002850-447235be-553f-43aa-b458-11d80ce36392\](https://user-images.githubusercontent.com/10355498/139003027-e359f09b-87be-4e66-ac71-a200f37a2fe8.png)

---

<div class="post-metadata">

### Author: ![jakeheron](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/jakeheron/32/116818_2.png) [@jakeheron](https://community.thunkable.com/u/jakeheron)
#### Post date: [October 27, 2021, 7:43am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/11 "2021-10-27T07:43:02Z")

</div>

Thank you for forwarding this issue, in the meantime, I have just used a button disguised as a text input and it works fine. Thanks @kartik14 and @tatiang for your help!

---

<div class="post-metadata">

### Author: ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)
#### Post date: [October 27, 2021, 8:16am UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/12 "2021-10-27T08:16:37Z")

</div>

@tatiang  
I tested the `Text Input` click behavior and found that in Thunkable Live App in the phone the click is registered every time you click on something else (the `text input` goes out of focus) and then back to it.

So if you click anywhere in the screen then click on the `Text Input` then the click will be registered (using the phone).

I think this is meaningful to differentiate the **click** from the **change** event.

---

<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: [October 27, 2021, 1:54pm UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/13 "2021-10-27T13:54:52Z")

</div>

Yes, it is helpful to know this. Do you mind adding a comment to the bug report I created?

---

<div class="post-metadata">

### Author: ![muneer](https://sea1.discourse-cdn.com/flex015/user_avatar/community.thunkable.com/muneer/32/75210_2.png) [@muneer](https://community.thunkable.com/u/muneer)
#### Post date: [October 27, 2021, 2:02pm UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/14 "2021-10-27T14:02:25Z")

</div>

I’ve just did.

---

<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, 1:14pm UTC](https://community.thunkable.com/t/help-needed-with-changing-list-viewer-to-different-variables/1581166/15 "2024-11-08T13:14:37Z")

</div>


