# System.gui attribute error

**URL:** <https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307>\
**Category:** Ignition\
**Tags:** perspective, scripting\
**Created:** [June 20, 2023, 9:02pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307 "2023-06-20T21:02:18Z")\
**Posts on this page:** 8\
**Page:** 1

<div class="post-metadata">

**Author:** ![Shlok\_Mundhra](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Shlok\_Mundhra](https://forum.inductiveautomation.com/u/Shlok_Mundhra)\
**Post date:** [June 20, 2023, 9:02pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/1 "2023-06-20T21:02:18Z")

</div>

Error running action 'dom.onClick' on IP\_Add@D/root/Button\_0: Traceback (most recent call last): File "function:runAction", line 2, in runAction File "module:IP\_addition", line 5, in confirmationBox AttributeError: 'com.inductiveautomation.ignition.common.script.Imm' object has no attribute 'gui'

Code is:  
def confirmationBox():  
system.gui.confirm("Are you sure you want to shutdown the plant?",  
"Really Shutdown?")

This runs on my script console but not when I call it from a event script?  
Any suggestions?

---

<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:** [June 20, 2023, 9:10pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/2 "2023-06-20T21:10:39Z")

</div>

`system.gui.*` and `system.nav.*` are entirely Vision only. The designer environment is a variation of Vision Client scope, so it works there.

---

<div class="post-metadata">

**Author:** ![Transistor](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/transistor/32/3380_2.png) [@Transistor](https://forum.inductiveautomation.com/u/Transistor)\
**Post date:** [June 20, 2023, 9:19pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/3 "2023-06-20T21:19:25Z")

</div>

> [@Shlok\_Mundhra](#):
>
> Code is:

Tip: Use the \</\> button to format code. This will preserve indents and apply syntax highlighting like this:

```auto
def confirmationBox():
    system.gui.confirm("Are you sure you want to shutdown the plant?",
                       "Really Shutdown?")

```

---

<div class="post-metadata">

**Author:** ![Shlok\_Mundhra](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Shlok\_Mundhra](https://forum.inductiveautomation.com/u/Shlok_Mundhra)\
**Post date:** [June 20, 2023, 9:21pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/4 "2023-06-20T21:21:05Z")

</div>

Got it. Thank you.  
When I launch my perspective window, it says "View not found": NO view configured for this page.  
Any suggestions for this?

---

<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:** [June 20, 2023, 9:25pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/5 "2023-06-20T21:25:03Z")

</div>

Go to the root node of the Perspective workspace (in the designer tree). It shows your page configurations there. One or more must be present, and each must have a starting view assigned.

---

<div class="post-metadata">

**Author:** ![Shlok\_Mundhra](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Shlok\_Mundhra](https://forum.inductiveautomation.com/u/Shlok_Mundhra)\
**Post date:** [June 21, 2023, 1:03pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/6 "2023-06-21T13:03:28Z")

</div>

Is there any system.gui equivalent for perspective?

---

<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:** [June 21, 2023, 1:20pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/7 "2023-06-21T13:20:33Z")

</div>

Bits and pieces. Some stuff is available as session properties. Some stuff is available from various `system.perspective.*` functions, particularly the `.projectInfo` and `.sessionInfo` functions.

Vision and Perspective are so fundamentally different that there are many things that have no 1:1 equivalent.

---

<div class="post-metadata">

**Author:** ![Shlok\_Mundhra](https://avatars.discourse-cdn.com/v4/letter/s/48db29/32.png) [@Shlok\_Mundhra](https://forum.inductiveautomation.com/u/Shlok_Mundhra)\
**Post date:** [June 21, 2023, 1:23pm UTC](https://forum.inductiveautomation.com/t/system-gui-attribute-error/75307/8 "2023-06-21T13:23:10Z")

</div>

Got it. Thank you so much 🙂
