# Access Java classes from Python

**URL:** <https://forum.inductiveautomation.com/t/access-java-classes-from-python/86718>\
**Category:** Ignition\
**Created:** [March 2, 2024, 3:39pm UTC](https://forum.inductiveautomation.com/t/access-java-classes-from-python/86718 "2024-03-02T15:39:57Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![ruevit](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ruevit/32/21028_2.png) [@ruevit](https://forum.inductiveautomation.com/u/ruevit)\
**Post date:** [March 2, 2024, 3:39pm UTC](https://forum.inductiveautomation.com/t/access-java-classes-from-python/86718/1 "2024-03-02T15:39:58Z")

</div>

I want to build a popup menu with parameters from other windows. The `system.gui.getWindowsNames()` gives me a list of windows. When I try to use `system.qui.getWindow()` it rises an exception saying that window is not opened.

I need some custom properties from the root container of these windows.

I found that `WindowInfo.getWindowInfo()` from [`com.inductiveautomation.factorypmi.application.model`](https://files.inductiveautomation.com/sdk/javadoc/ignition79/790-beta1/com/inductiveautomation/factorypmi/application/model/WindowInfo.html) package can give me some information about a window. Is it posible to use it and if so, then how? I don't know what to import to get access to `WindowInfo` class.

---

<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:** [March 2, 2024, 3:58pm UTC](https://forum.inductiveautomation.com/t/access-java-classes-from-python/86718/2 "2024-03-02T15:58:54Z")

</div>

> [@ruevit](#):
>
> I need some custom properties from the root container of these windows.

The root container doesn't exist if the window isn't open. So, no, you cannot do this. I recommend you create a constant in a library script to supply the information when the windows are closed. Consider using a script in the designer to open all of the windows of interest, then another to collect this information and output it in the script console with `repr()`. That should be close to what you need for the library script constant.

---

<div class="post-metadata">

**Author:** ![ruevit](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ruevit/32/21028_2.png) [@ruevit](https://forum.inductiveautomation.com/u/ruevit)\
**Post date:** [March 4, 2024, 8:46am UTC](https://forum.inductiveautomation.com/t/access-java-classes-from-python/86718/3 "2024-03-04T08:46:50Z")

</div>

I decided to use a dataset as it looks like easiest way.

But there should be answer because the information exists in the window object even it is not opened. The question is how to access it.

Thank you for your help.

---

<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:** [March 4, 2024, 1:00pm UTC](https://forum.inductiveautomation.com/t/access-java-classes-from-python/86718/4 "2024-03-04T13:00:12Z")

</div>

> [@ruevit](#):
>
> even it is not opened.

It is in a compressed, serialized, binary format that is only decoded by opening (because the decoding process actually instantiates the components).

So, no, you cannot access the information without opening the window(s).
