# Trigger Report viewer open in new tab button from script

**URL:** <https://forum.inductiveautomation.com/t/trigger-report-viewer-open-in-new-tab-button-from-script/95207>\
**Category:** Ignition\
**Tags:** reporting, perspective\
**Created:** [August 27, 2024, 1:29pm UTC](https://forum.inductiveautomation.com/t/trigger-report-viewer-open-in-new-tab-button-from-script/95207 "2024-08-27T13:29:26Z")\
**Posts on this page:** 3\
**Page:** 1

<div class="post-metadata">

**Author:** ![Noah\_Casey](https://avatars.discourse-cdn.com/v4/letter/n/e480ec/32.png) [@Noah\_Casey](https://forum.inductiveautomation.com/u/Noah_Casey)\
**Post date:** [August 27, 2024, 1:29pm UTC](https://forum.inductiveautomation.com/t/trigger-report-viewer-open-in-new-tab-button-from-script/95207/1 "2024-08-27T13:29:27Z")

</div>

I'm using perspective with the report viewer I noticed there is a button on the report viewer to open the report in a new tab with the ability to print to a local printer using this method.

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/7/9/79f9238926a9ad78a55d77ec66780b10f75def13.png)

Is there any way to replicate this same functionality through scripting?  
The idea is to fill out values/parameters of a report have a button the user can click and it will generate the report in a new tab without actually seeing the report.

---

<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:** [August 27, 2024, 1:33pm UTC](https://forum.inductiveautomation.com/t/trigger-report-viewer-open-in-new-tab-button-from-script/95207/2 "2024-08-27T13:33:15Z")

</div>

> [@Noah\_Casey](#):
>
> without actually seeing the report

Not this part. At least, not in Perspective. You can connect your printer(s) to the gateway, and send from there, or use Vision.

---

<div class="post-metadata">

**Author:** ![Noah\_Casey](https://avatars.discourse-cdn.com/v4/letter/n/e480ec/32.png) [@Noah\_Casey](https://forum.inductiveautomation.com/u/Noah_Casey)\
**Post date:** [August 27, 2024, 5:47pm UTC](https://forum.inductiveautomation.com/t/trigger-report-viewer-open-in-new-tab-button-from-script/95207/3 "2024-08-27T17:47:49Z")

</div>

After some testing I figured out a way to do this:

This is what the screen looks like:  
 ![ItWorks2](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/2/32980123f4c94b16d34de71761ed9ffcee7dfb04.gif)

Users can input the values then the report generates and opens in a new tab allowing users to print to any printer connected to the device.
