# Report Print from Button in Perspective (Need Help!)

**URL:** <https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482>\
**Category:** General Discussion\
**Tags:** ignition81, reporting, perspective\
**Created:** [November 3, 2023, 7:03pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482 "2023-11-03T19:03:40Z")\
**Posts on this page:** 6\
**Page:** 1

<div class="post-metadata">

**Author:** ![Eagel007](https://avatars.discourse-cdn.com/v4/letter/e/7bcc69/32.png) [@Eagel007](https://forum.inductiveautomation.com/u/Eagel007)\
**Post date:** [November 3, 2023, 7:03pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482/1 "2023-11-03T19:03:40Z")

</div>

Hi,

I am using following code to print report.

Reportpath = self.view.custom.ReportName  
project = "ProjectName"  
settings = {"primaryPrinterName":'MyPrinter', "copies":1}   
system.report.executeAndDistribute(path=Reportpath, project=project, action="print", actionSettings=settings)

I am getting Error: Could not print report to primary printer.

My primary printer is also installed on Gateway and is working. What could be the cause?

Thanks

---

<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:** [November 3, 2023, 7:07pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482/2 "2023-11-03T19:07:43Z")

</div>

> [@Eagel007](#):
>
> My primary printer is also installed on Gateway and is working.

Working for a user logged into the server is not sufficient (a background service on a server is independent of any desktop user), as background services generally run as an isolated user. For a network printer, your background service may need additional privileges. It may also need to have its default printer set, separately.

---

<div class="post-metadata">

**Author:** ![Eagel007](https://avatars.discourse-cdn.com/v4/letter/e/7bcc69/32.png) [@Eagel007](https://forum.inductiveautomation.com/u/Eagel007)\
**Post date:** [November 3, 2023, 7:26pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482/3 "2023-11-03T19:26:54Z")

</div>

we have operator screens and each screen has this printer installed. Just curious what could prevent it from printing. If I print a PDF document from desktop, it would print just fine. However through ignition its giving the error

---

<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:** [November 3, 2023, 7:32pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482/4 "2023-11-03T19:32:54Z")

</div>

You've tagged this as Perspective. Perspective clients are web browsers, not local applications. So the printer settings on client are utterly meaningless to the behavior of any scripted print operation. (All Perspective scripts run in the gateway server, in that background service, and therefore require printers to be set up for the gateway to use.)

To print a report to a **locally-defined** printer requires either downloading the PDF and letting Adobe print it, or opening in a browser tab to let the browser's native PDF support print it.

Web browsers simply do not permit Ignition **direct** access to a local printer.

---

<div class="post-metadata">

**Author:** ![Eagel007](https://avatars.discourse-cdn.com/v4/letter/e/7bcc69/32.png) [@Eagel007](https://forum.inductiveautomation.com/u/Eagel007)\
**Post date:** [November 3, 2023, 7:38pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482/5 "2023-11-03T19:38:06Z")

</div>

![image](https://us1.discourse-cdn.com/inductiveautomation/original/3X/3/1/31183d92747279cd810b97821331cc12843012a6.png)  
Can allow OpenInTab open in embedded view or in same tab? we have Kiosk mode, so if we go to OpenInTab, we cant move back.

---

<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:** [November 3, 2023, 7:39pm UTC](https://forum.inductiveautomation.com/t/report-print-from-button-in-perspective-need-help/81482/6 "2023-11-03T19:39:47Z")

</div>

I haven't really played with Kiosk mode.
