# Download Ignition QR Code

**URL:** <https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122>\
**Category:** Ignition\
**Tags:** ignition81, perspective\
**Created:** [March 24, 2025, 8:35pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122 "2025-03-24T20:35:32Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![richhull](https://avatars.discourse-cdn.com/v4/letter/r/b19c9b/32.png) [@richhull](https://forum.inductiveautomation.com/u/richhull)\
**Post date:** [March 24, 2025, 8:35pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/1 "2025-03-24T20:35:32Z")

</div>

I have a system in ignition that generates QR codes. So far I have it where the user can create them or delete them on a screen. However, I also want the user to have the ability to download the QR code to print it out. Is there a way I could go about doing it?

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 24, 2025, 8:37pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/2 "2025-03-24T20:37:04Z")

</div>

You can script something with `system.perspective.download`. It would require that you generate the QR as an image or pdf and provide the file data to the function call.

> **[system.perspective.download | Ignition User Manual](https://www.docs.inductiveautomation.com/docs/8.1/appendix/scripting-functions/system-perspective/system-perspective-download)**
>
> Downloads data from the Gateway to a device running a Session.

---

<div class="post-metadata">

**Author:** ![richhull](https://avatars.discourse-cdn.com/v4/letter/r/b19c9b/32.png) [@richhull](https://forum.inductiveautomation.com/u/richhull)\
**Post date:** [March 24, 2025, 8:42pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/3 "2025-03-24T20:42:57Z")

</div>

how would I go about converting the QR component into an image?

---

<div class="post-metadata">

**Author:** ![ryan.white](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/ryan.white/32/73193_2.png) [@ryan.white](https://forum.inductiveautomation.com/u/ryan.white)\
**Post date:** [March 24, 2025, 8:50pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/4 "2025-03-24T20:50:14Z")

</div>

If you have the reporting module you can create a report that uses the same QR code format as the component and call `system.report.execute` while passing the QR code text/data as a parameter and hand the return from that call to the `download` call.

If you don't want to use the reporting module then you would need to find out how to generate an image with a barcode on the fly and pass that data to the `download` call. There are some java libraries out there for generating barcodes/QR codes, but I don't know if Ignition includes them in its standard library.(you can technically add to this library)

---

<div class="post-metadata">

**Author:** ![djs](https://avatars.discourse-cdn.com/v4/letter/d/e47774/32.png) [@djs](https://forum.inductiveautomation.com/u/djs)\
**Post date:** [March 24, 2025, 9:02pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/5 "2025-03-24T21:02:01Z")

</div>

You could also accomplish this with the [requestPrint](https://www.docs.inductiveautomation.com/docs/8.1/ignition-modules/perspective/working-with-perspective-components/component-events-and-actions#request-print-action) action targeting the _Component_. Though the Reporting Module solution from [ryan.white](https://forum.inductiveautomation.com/u/ryan.white) is definitely the cleaner option, as you wouldn't be relying on the browser's interpretation of your view.

---

<div class="post-metadata">

**Author:** ![paul-griffith](https://sea1.discourse-cdn.com/inductiveautomation/user_avatar/forum.inductiveautomation.com/paul-griffith/32/37249_2.png) [@paul-griffith](https://forum.inductiveautomation.com/u/paul-griffith)\
**Post date:** [March 24, 2025, 9:02pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/6 "2025-03-24T21:02:07Z")

</div>

You can invoke the `requestPrint` method _from a component reference directly_:

> **[Perspective Component Methods | Ignition User Manual](https://docs.inductiveautomation.com/docs/8.1/ignition-modules/perspective/scripting-in-perspective/perspective-component-methods#requesting-print)**
>
> A component method is a function that is defined on a component object. For example, this is how we would call a component method defined on the component object self:

---

<div class="post-metadata">

**Author:** ![richhull](https://avatars.discourse-cdn.com/v4/letter/r/b19c9b/32.png) [@richhull](https://forum.inductiveautomation.com/u/richhull)\
**Post date:** [March 24, 2025, 9:07pm UTC](https://forum.inductiveautomation.com/t/download-ignition-qr-code/104122/7 "2025-03-24T21:07:16Z")

</div>

This was exactly what I was looking for. Thank you!
