Put a dictionary onto a root container as a custom property?

I have a popup window that can be called from multiple other windows.

Depending on which main window calls the popup I want to determine the UI update when the user is done creating/updating the record.

I already have a generic way to update the UI for the current user using a list of dictionaries (which have sub dictionaries which makes this a little ill-suited for a dataset).

Therefore I think the easiest way for me to do this would be to put the UI Update data as a custom property on the root container of the window which will then get fed to my generic message handler that updates the UI.

I am in script console and I thought .putClientProperty was the way to go but this

win = system.gui.getWindow("Pop_AddEditUser")
rc = win.getRootContainer()

for prop in rc.properties:
	if prop == 'updateAfter':
		print prop
for thing in dir(rc):
	if thing == 'updateAfter':
		print thing


shows me nothing, I can’t seem to access, and the last line gives me an attribute error.

Is there a way to do this?

I’m not positive, but a client property isn’t the same thing as a custom property, so wouldn’t the last line be this?


Ahh, I should have realized to use a getter after using a setter. That works, thank you!

You are correct. .getClientProperty() is the only way to retrieve them.