# Listing all JComponent Client Properties for a component/window

**URL:** <https://forum.inductiveautomation.com/t/listing-all-jcomponent-client-properties-for-a-component-window/41034>\
**Category:** Ignition\
**Created:** [November 30, 2020, 2:23am UTC](https://forum.inductiveautomation.com/t/listing-all-jcomponent-client-properties-for-a-component-window/41034 "2020-11-30T02:23:25Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![bmusson](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/bmusson/32/87530_2.png) [@bmusson](https://forum.inductiveautomation.com/u/bmusson)\
**Post date:** [November 30, 2020, 2:23am UTC](https://forum.inductiveautomation.com/t/listing-all-jcomponent-client-properties-for-a-component-window/41034/1 "2020-11-30T02:23:25Z")

</div>

Say I’m adding some client properties (usually functions) to a window:

```auto
window = system.nav.openWindow(path)
window.putClientProperty('p1', p1)
window.putClientProperty('p2', p2)

```

Then I can read these back by name:

```auto
window = system.gui.getParentWindow(event)
p1= window.getClientProperty('p1')
p2= window.getClientProperty('p2')

```

What options do I have to enumerate through the client properties dictionary? I’d like to be able to copy all the client properties from one window to another (where I may not know the property names ahead of time).

I think I can solve this by either 1.) Using a client property containing a list of relevant property names or 2.) Always using a single known client property, but it seems like there should be a way to list the dictionary keys directly.

```auto
window.putClientProperty('propertyList', ['p1', 'p2'])

```

```auto
window.putClientProperty('myProperties', {'p1': p1, 'p2', p2})

```

---

<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:** [November 30, 2020, 11:05am UTC](https://forum.inductiveautomation.com/t/listing-all-jcomponent-client-properties-for-a-component-window/41034/2 "2020-11-30T11:05:09Z")

</div>

There’s a private .getClientProperties() you could try to access from reflection. However, the comments on the documentation for .putClientProperty() pretty clearly encourage you to **not** go wild with these. I always use a static key for any repeatable purpose. I would examine your use-case to make the property names consistent/known.

---

<div class="post-metadata">

**Author:** ![bmusson](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/bmusson/32/87530_2.png) [@bmusson](https://forum.inductiveautomation.com/u/bmusson)\
**Post date:** [December 2, 2020, 1:33am UTC](https://forum.inductiveautomation.com/t/listing-all-jcomponent-client-properties-for-a-component-window/41034/3 "2020-12-02T01:33:50Z")

</div>

Interesting side note; custom methods are stored in plain text under the client property _vision.custom.functions_

```auto
functions = window.getClientProperty('vision.custom.functions')
print functions

```

```auto
{newMethod: def newMethod(self):
	"""
	Arguments:
		self: A reference to the component instance this method is invoked on. This argument
		  is automatic and should not be specified when invoking this method.
	"""
	# A custom method.
	pass}

```

I don’t know why someone would want to programmatically add custom methods, but if you want to the tools are here.
