# Why can't custom properties and methods be accessed from a component that is obtained using SwingUtilities.getAncestorOfClass?

**URL:** <https://forum.inductiveautomation.com/t/why-cant-custom-properties-and-methods-be-accessed-from-a-component-that-is-obtained-using-swingutilities-getancestorofclass/78606>\
**Category:** Ignition\
**Tags:** vision, scripting\
**Created:** [August 31, 2023, 10:07am UTC](https://forum.inductiveautomation.com/t/why-cant-custom-properties-and-methods-be-accessed-from-a-component-that-is-obtained-using-swingutilities-getancestorofclass/78606 "2023-08-31T10:07:05Z")\
**Posts on this page:** 1\
**Showing post:** 2

<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 31, 2023, 2:26pm UTC](https://forum.inductiveautomation.com/t/why-cant-custom-properties-and-methods-be-accessed-from-a-component-that-is-obtained-using-swingutilities-getancestorofclass/78606/2 "2023-08-31T14:26:37Z")

</div>

Custom properties are added to the java standard jython conversion by IA's `PyComponentWrapper`. For a complete discussion, read this entire topic:

> [@Transaction groups triggered expression item updating when trigger is false](https://forum.inductiveautomation.com/t/transaction-groups-triggered-expression-item-updating-when-trigger-is-false/17196/14):
>
> Ok, so I’ve been down the rabbit hole and found Ignition’s (undocumented) PyComponentWrapper. I haven’t deciphered it enough to be sure, but it seems to be invoked only for particular situations, based on the string constants in the class file (like “getComponent” and “getComponents”). To play with this, I constructed a conversion adapter like so: public class PyComponentAdapter implements PyObjectAdapter { public PyComponentAdapter() {} @Override public boolean canAdapt(Object jObj) { …

TL/DR: Install my ~~Simulation Aids~~ _Integration Toolkit_ module to magically fix this, everywhere in Ignition. ~~There is _ **no other solution** _ until IA eventually does this first party.~~ _See below._

---

_[View the full topic](https://forum.inductiveautomation.com/t/why-cant-custom-properties-and-methods-be-accessed-from-a-component-that-is-obtained-using-swingutilities-getancestorofclass/78606)._
