# Accessing components within a template instance

**URL:** <https://forum.inductiveautomation.com/t/accessing-components-within-a-template-instance/36638>\
**Category:** Ignition\
**Tags:** vision, scripting\
**Created:** [July 13, 2020, 2:32pm UTC](https://forum.inductiveautomation.com/t/accessing-components-within-a-template-instance/36638 "2020-07-13T14:32:27Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![tecnoeletronic](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/tecnoeletronic/32/50975_2.png) [@tecnoeletronic](https://forum.inductiveautomation.com/u/tecnoeletronic)\
**Post date:** [July 13, 2020, 2:32pm UTC](https://forum.inductiveautomation.com/t/accessing-components-within-a-template-instance/36638/1 "2020-07-13T14:32:27Z")

</div>

Hi,

i have a window. In this windows i added a CustomTemplate and a Button.  
Is there any way to access to a component property inside the CustomTemplate using scripting on button? Or the only way is to use a CustomProperty in Template and bind it to component property?

---

<div class="post-metadata">

**Author:** ![code\_skin](https://avatars.discourse-cdn.com/v4/letter/c/43a26b/32.png) [@code\_skin](https://forum.inductiveautomation.com/u/code_skin)\
**Post date:** [July 13, 2020, 2:41pm UTC](https://forum.inductiveautomation.com/t/accessing-components-within-a-template-instance/36638/2 "2020-07-13T14:41:47Z")

</div>

It is definitely possible.  
Have a look here:

> **[Vision Templates | Ignition User Manual](https://docs.inductiveautomation.com/docs/8.1/ignition-modules/vision/vision-templates#accessing-components-inside-a-template-instance)**
>
> Templates are a simple but a very powerful feature in Ignition that you can use with the Vision windows. The power comes from the ability to modify only the template in one location while affecting all of the instances used throughout the project....

_edit_: updated doc link.

---

<div class="post-metadata">

**Author:** ![tecnoeletronic](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/tecnoeletronic/32/50975_2.png) [@tecnoeletronic](https://forum.inductiveautomation.com/u/tecnoeletronic)\
**Post date:** [July 13, 2020, 6:24pm UTC](https://forum.inductiveautomation.com/t/accessing-components-within-a-template-instance/36638/3 "2020-07-13T18:24:31Z")

</div>

Thanks!! tomorrow i’m going to test it!
