# Creating a list of element thats contains 'string' from another list

**URL:** <https://community.thunkable.com/t/creating-a-list-of-element-thats-contains-string-from-another-list/3123389>\
**Category:** Questions about Thunkable X\
**Tags:** beginner, bluetooth, list\
**Created:** [August 2, 2024, 11:31am UTC](https://community.thunkable.com/t/creating-a-list-of-element-thats-contains-string-from-another-list/3123389 "2024-08-02T11:31:04Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ocorbo](https://avatars.discourse-cdn.com/v4/letter/o/ad7895/32.png) [@ocorbo](https://community.thunkable.com/u/ocorbo)\
**Post date:** [August 2, 2024, 11:31am UTC](https://community.thunkable.com/t/creating-a-list-of-element-thats-contains-string-from-another-list/3123389/1 "2024-08-02T11:31:04Z")

</div>

hi, really beginner here, just starting with this thunkable.

im using bluetooth scan and i would like to create a list with all the near devices. then parse it to create another list with all the ones that has a certain string in their name and finally only show them. how would i do it ?

here’s an image of what i’ve done so far

 ![Capture d’écran, le 2024-08-02 à 07.30.08](https://us1.discourse-cdn.com/flex015/uploads/thunkable/original/3X/9/1/91a715a2b0b75a2f2f63d6b30a7aebe67048388a.png)

---

<div class="post-metadata">

**Author:** ![brianl](https://avatars.discourse-cdn.com/v4/letter/b/f14d63/32.png) [@brianl](https://community.thunkable.com/u/brianl)\
**Post date:** [August 6, 2024, 7:10pm UTC](https://community.thunkable.com/t/creating-a-list-of-element-thats-contains-string-from-another-list/3123389/2 "2024-08-06T19:10:25Z")

</div>

Hi ocorbo, welcome to Thunkable! 🎉

Be sure to check out [How to ask Great Questions v2.0](https://community.thunkable.com/t/how-to-ask-great-questions-v2-0/2689983/1), the [Community Guidelines](https://community.thunkable.com/t/community-guidelines/78/8), and our [Getting Started Guide](https://docs.thunkable.com/getting-started/get-started) to make the best of your Thunkable Community experience!

As for your question, there are a few areas that need to be corrected.

You have “set app variable app variable BluetoohDevicesNameList” after your scan. There is a dedicated [“set variable” block](https://docs.thunkable.com/blocks/blocks/variables-overview/variables#set-variable-to) you should use instead. You might have to click on the dropdown and select the variable you want to set.

You need [loop](https://docs.thunkable.com/blocks/blocks/control#for-each-item-j-in-list) through the app variable BluetoothDevicesNameList and if “j” contains “pdstal”, then you do what you need to with “j” as it contains the name you are looking for.

---

<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:** [November 4, 2024, 7:10pm UTC](https://community.thunkable.com/t/creating-a-list-of-element-thats-contains-string-from-another-list/3123389/3 "2024-11-04T19:10:30Z")

</div>

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