# Perspective popup view size

**URL:** <https://forum.inductiveautomation.com/t/perspective-popup-view-size/31300>\
**Category:** Ignition\
**Created:** [January 15, 2020, 4:16pm UTC](https://forum.inductiveautomation.com/t/perspective-popup-view-size/31300 "2020-01-15T16:16:09Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![weertske](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/weertske/32/3353_2.png) [@weertske](https://forum.inductiveautomation.com/u/weertske)\
**Post date:** [January 15, 2020, 4:16pm UTC](https://forum.inductiveautomation.com/t/perspective-popup-view-size/31300/1 "2020-01-15T16:16:09Z")

</div>

Maybe I am missing it somewhere in the manual but I need to be able to set popup width in % rather than in pixels. Pixels do me little good when I don’t know the viewport width.

---

<div class="post-metadata">

**Author:** ![cmallonee](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/cmallonee/32/6416_2.png) [@cmallonee](https://forum.inductiveautomation.com/u/cmallonee)\
**Post date:** [January 15, 2020, 4:41pm UTC](https://forum.inductiveautomation.com/t/perspective-popup-view-size/31300/2 "2020-01-15T16:41:19Z")

</div>

If you’re using the Popup Action, you’re currently limited to pixel count. If you switch over to using scripting methods, like openPopup, closePopup, or togglePopup, then you have the option of supplying a `position` argument.

The following code would open a Popup which takes up 50% of the width of the screen:

```auto
system.perspective.togglePopup(id='<unique_id>',view='<view_of_your_popup',position={'width':'50%'})

```

---

<div class="post-metadata">

**Author:** ![weertske](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/weertske/32/3353_2.png) [@weertske](https://forum.inductiveautomation.com/u/weertske)\
**Post date:** [January 15, 2020, 4:45pm UTC](https://forum.inductiveautomation.com/t/perspective-popup-view-size/31300/3 "2020-01-15T16:45:40Z")

</div>

Thank you. I am using scripting. I just didn’t think to put the value in quotes.
