# Airtable Messaging App

**URL:** <https://community.thunkable.com/t/airtable-messaging-app/1107483>\
**Category:** Questions about Thunkable X\
**Tags:** chat, beginner, lists, list, cloud-variable\
**Created:** [February 18, 2021, 4:45pm UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483 "2021-02-18T16:45:11Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![p.powercoders1i0t](https://avatars.discourse-cdn.com/v4/letter/p/f07891/32.png) [@p.powercoders1i0t](https://community.thunkable.com/u/p.powercoders1i0t)\
**Post date:** [February 18, 2021, 4:45pm UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/1 "2021-02-18T16:45:12Z")

</div>

Hi! I’m trying to make this chat app and have only specific messages displayed, what I imagine is that each “chat” has a unique “access” code.

Here is my code so far:

**Note: This was apart of the color chat app on Thunkable.**

So the page starts and loads the messages in a cloud variable

I’m attempting to filter the messages like this:

 ![Screenshot 2021-02-18 083637](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/7/b/7b27650150b5c15e623258add108e217956e9c07.png)

and here’s the code from the color chat app that sends a message (note: I added the code object and set it to 123456 (I’ll change this things working)) I’m trying to get the app to display only the messages with the code 123456

 ![Screenshot 2021-02-18 083816](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/a/0/a06b1ba13a4011993b1991bfbee120b76055f2f8.png)

But Right now I see no messages and I’m unsure why?

 ![Screenshot 2021-02-18 084610](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/6/2/62b944a2101c8cb40a5c1c73bcbc04740ba95679.png)

I apologize for not being able to see all of my code, it was too big to fit on the screen. You can remix the app here!:

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

I would appreciate any help or suggestions!

---

<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:** [February 18, 2021, 10:36pm UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/2 "2021-02-18T22:36:45Z")

</div>

The original object structure does not have a property with the name `code` and therefore your filter condition will always be false and the list will have no entries,

---

<div class="post-metadata">

**Author:** ![p.powercoders1i0t](https://avatars.discourse-cdn.com/v4/letter/p/f07891/32.png) [@p.powercoders1i0t](https://community.thunkable.com/u/p.powercoders1i0t)\
**Post date:** [February 19, 2021, 4:05am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/4 "2021-02-19T04:05:09Z")

</div>

Thank you for your help! I added this:

 ![Screenshot 2021-02-18 184413](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/1/d/1d0c0f7f4bca629c8337df5aa8d2343c62d97e48.png)

but it still doesn’t work, any ideas?

---

<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:** [February 19, 2021, 8:17am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/5 "2021-02-19T08:17:24Z")

</div>

From the conditions in the code this addition is for new chats and not for existing ones. So for any existing chat the `code` property will not be available.

---

<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:** [February 19, 2021, 8:49am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/6 "2021-02-19T08:49:18Z")

</div>

You can’t count to “cloud variable general” in the second loop of the LoadMessages function because it’s a list not a number:

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

You have to count to “ **length of** cloud variable general” instead:

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

It also seems strange to me that you are adding the found list item, j, to the end of the same list you are searching (cloud variable general). That would duplicate the existing chat message. Is that what you mean to be doing? Normally, I’d use a separate list for that so that you store the “found” results in an empty list and use that list to load when the scene opens.

I can see the entered and stored messages (when the screen loads) after I fixed the loop count block that I mentioned above.

---

<div class="post-metadata">

**Author:** ![p.powercoders1i0t](https://avatars.discourse-cdn.com/v4/letter/p/f07891/32.png) [@p.powercoders1i0t](https://community.thunkable.com/u/p.powercoders1i0t)\
**Post date:** [February 20, 2021, 1:29am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/8 "2021-02-20T01:29:56Z")

</div>

Thank you! I did what you suggested (adding the length of block) and it worked!

Now I’m trying to separate the found messages in a list

here’s a snippet of what I changed:

 ![Screenshot 2021-02-19 172122](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/7/d/7d4f51ab65a6d1d29df6a9234ebdc18aca423c92.png)

But the sames things happening where the message just disappear when I input it? I think I made it work once because I can see a message with the string “sssss” but i’ve been unsuccessful in making it work.

If you’d be willing to take a closer look here’s the remix link: [Thunkable](https://x.thunkable.com/copy/d0bd655d4038fdd8b73dcb2ca43d0b54)

Thanks again for the help!

---

<div class="post-metadata">

**Author:** ![p.powercoders1i0t](https://avatars.discourse-cdn.com/v4/letter/p/f07891/32.png) [@p.powercoders1i0t](https://community.thunkable.com/u/p.powercoders1i0t)\
**Post date:** [February 21, 2021, 12:49am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/9 "2021-02-21T00:49:17Z")

</div>

**UPDATE:**

I’ve run into another problem. When i preview my app as a web app it freezes and can’t see if my code is executing correctly.

I got to work with the help of @muneer and @tatiang (thanks for the help!)  
before i tried to filter the list of messages in the could variable “general”

After I started to filter the cloud variable general the windows began to freeze when i preview it as web app.  
now when i go back to both they both freeze.

I’m going to try and preview it on my phone but was wondering if anyone would be able to test out one of two links below to see if they can see the program without it freezing.

Link 1 (non-filtered list): [Thunkable](https://x.thunkable.com/copy/e738f081838ff90a3f92eb7c76edaec0)

Link 2 (filtered list): [Thunkable](https://x.thunkable.com/copy/aae4f50ac4903eab22d84a43daf1ca40)

thanks in advance,

---

<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:** [February 21, 2021, 11:22am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/10 "2021-02-21T11:22:12Z")

</div>

I tested the two apps  
1 - The non-filtered one works but my text is not shown.  
2 - The filtered one gets stuck.

---

<div class="post-metadata">

**Author:** ![p.powercoders1i0t](https://avatars.discourse-cdn.com/v4/letter/p/f07891/32.png) [@p.powercoders1i0t](https://community.thunkable.com/u/p.powercoders1i0t)\
**Post date:** [February 22, 2021, 11:12pm UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/11 "2021-02-22T23:12:45Z")

</div>

Thank you muneer. I think i’ll discard (not delete, just move on) from this post as I can’t figure out how to do this and I also realize this will probably cost me more work in the end. I’m trying to integrate a “chat” feature in my app that doesn’t require a phone number.

here’s the chat app I was trying to show only specific list items in the “general” cloud variable, I couldn’t figure what i was doing wrong because the screen kept on freezing: [Thunkable](https://x.thunkable.com/copy/2db42319e95bffcea220859a6ece2300)

But Thanks for all the help muneer and tating!

---

<div class="post-metadata">

**Author:** ![p.powercoders1i0t](https://avatars.discourse-cdn.com/v4/letter/p/f07891/32.png) [@p.powercoders1i0t](https://community.thunkable.com/u/p.powercoders1i0t)\
**Post date:** [February 24, 2021, 12:58am UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/12 "2021-02-24T00:58:49Z")

</div>

Hi @muneer and @tatiang and anyone, now i know I said I was done with this but I thought maybe i could use airtable to make this work …

I managed to retrieve the data from my airtable but when i try to clone it can’t retrieve the messages.

here’s the code so far:

I sort the data like so and also enter it into a list viewer (i did this to check if it was sorting how i intended)

 ![Screenshot 2021-02-23 164508](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/c/7/c7f679c0e3f617a7bc7e9d6b38a011913c3e8c48.png)

then (where i’m running into my problem) when i try to clone the messages it clones the styled message for each of the messages found in the first snippet  
but when it doesn’t show the messages and i’m unsure why?

 ![Screenshot 2021-02-23 165639](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/5/2/52403f98ff7887f8c1fc718da2d69a833ff5fb24.png)

Edit: here’s a link to the project if you’d like: [Thunkable](https://x.thunkable.com/copy/e83ba6f034ccf1b94a0428e14205e647)

---

<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:29pm UTC](https://community.thunkable.com/t/airtable-messaging-app/1107483/13 "2024-11-08T13:29:19Z")

</div>


