# Bind FlexRepeater Instances to Tag List

**URL:** <https://forum.inductiveautomation.com/t/bind-flexrepeater-instances-to-tag-list/95267>\
**Category:** Ignition\
**Tags:** perspective\
**Created:** [August 28, 2024, 2:04pm UTC](https://forum.inductiveautomation.com/t/bind-flexrepeater-instances-to-tag-list/95267 "2024-08-28T14:04:21Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Gillian\_Carter](https://avatars.discourse-cdn.com/v4/letter/g/8edcca/32.png) [@Gillian\_Carter](https://forum.inductiveautomation.com/u/Gillian_Carter)\
**Post date:** [August 28, 2024, 2:04pm UTC](https://forum.inductiveautomation.com/t/bind-flexrepeater-instances-to-tag-list/95267/1 "2024-08-28T14:04:21Z")

</div>

I have a flex repeater, I would like to bind the instances somehow to a list of tag paths, so there is one instance for each tag path. I can do it all in a script, but am stuck on what type of binding to start with to then move on to add a script binding. The screen shot below I have just manually added the instances, but would like to select a tag folder and get the list of tag paths to get information from them to fill in to the instances. can I just make a json string in an expression and fill it?

 ![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/5/a/5ab16f29116f69ab4213f59ec62db9b09a7c317b.png)

---

<div class="post-metadata">

**Author:** ![pturmel](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/pturmel/32/3295_2.png) [@pturmel](https://forum.inductiveautomation.com/u/pturmel)\
**Post date:** [August 28, 2024, 2:16pm UTC](https://forum.inductiveautomation.com/t/bind-flexrepeater-instances-to-tag-list/95267/2 "2024-08-28T14:16:04Z")

</div>

Where do you have the list of tag paths? If in a property, use a property binding, then a script transform.

---

<div class="post-metadata">

**Author:** ![Rats](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/rats/32/68478_2.png) [@Rats](https://forum.inductiveautomation.com/u/Rats)\
**Post date:** [August 28, 2024, 7:55pm UTC](https://forum.inductiveautomation.com/t/bind-flexrepeater-instances-to-tag-list/95267/3 "2024-08-28T19:55:48Z")

</div>

For flex repeaters in conjunction with reading from folders, I've been just using an event handler that runs on start up and then building my flex repeater off that.  
Something like this:

```python
def runAction(self):
	tags = system.tag.browse("[Example]Example")
	options = []
	for i in range(len(tags)):
		options.append({"asset": tags[i]['fullPath']})
	self.props.instances = options

```

You could replace fullPath with whatever you're trying to fill into the flex repeater. Hope that helps!

---

<div class="post-metadata">

**Author:** ![nminchin](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/nminchin/32/6911_2.png) [@nminchin](https://forum.inductiveautomation.com/u/nminchin)\
**Post date:** [August 28, 2024, 9:11pm UTC](https://forum.inductiveautomation.com/t/bind-flexrepeater-instances-to-tag-list/95267/4 "2024-08-28T21:11:32Z")

</div>

Unrelated, but from your screenshot it looks like you could do with a lot of `gap` style props being set to give your components in flex containers some space around them rather than all touching each other. `gap` can (and should, imo) be used for every flex container.  
Eg

```python
style:
   gap: 3px

```
