# Scripting to get list of Custom GUI component by type

**URL:** <https://forum.inductiveautomation.com/t/scripting-to-get-list-of-custom-gui-component-by-type/11535>\
**Category:** General Discussion\
**Created:** [April 19, 2016, 9:39am UTC](https://forum.inductiveautomation.com/t/scripting-to-get-list-of-custom-gui-component-by-type/11535 "2016-04-19T09:39:43Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![ian](https://avatars.discourse-cdn.com/v4/letter/i/bb73d2/32.png) [@ian](https://forum.inductiveautomation.com/u/ian)\
**Post date:** [April 19, 2016, 9:39am UTC](https://forum.inductiveautomation.com/t/scripting-to-get-list-of-custom-gui-component-by-type/11535/1 "2016-04-19T09:39:43Z")

</div>

Is there any way to get the list of Custom GUI components under Root Container by type in Ignition in the Component’s event’s scripting?

1. I am just looking for a way to get single Custom GUI component type (say, having name of signal)
2. All my Custom GUI components in the Window are having the same starting name string (such as signal 1, signal 2, signal 123 and so on). Can this name property be exploited to get all the GUI components in the Window whose name starting with, say, “signal”?

---

<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:** [April 19, 2016, 12:21pm UTC](https://forum.inductiveautomation.com/t/scripting-to-get-list-of-custom-gui-component-by-type/11535/2 "2016-04-19T12:21:02Z")

</div>

See other answer.  
Also look at python’s [.startswith()](http://www.jython.org/docs/library/stdtypes.html#string-methods) string method.

---

<div class="post-metadata">

**Author:** ![ian](https://avatars.discourse-cdn.com/v4/letter/i/bb73d2/32.png) [@ian](https://forum.inductiveautomation.com/u/ian)\
**Post date:** [April 20, 2016, 3:39am UTC](https://forum.inductiveautomation.com/t/scripting-to-get-list-of-custom-gui-component-by-type/11535/3 "2016-04-20T03:39:54Z")

</div>

Ok, I will combine the getComponent() with string startswith(). Thanks for the direction!
