Post Closed
226
Views
6
Comments
Could someone give me a solution for printing data on outsystems

So I'm just starting with OutSystems now, and I've been given a challenge. I've already completed the frontend, which involves a scenario where a person fills out a form, for example: name, age, date, and so on. Once they fill it out, there should be a print button. When they click this button, it should print the data they entered in a PDF template. However, for now, I just want to focus on the part of printing the data entered into the input fields. After that, I'll address the printing layout. Is it possible to do this? 

2019-06-15 21-39-22
Afonso Carvalho
 
MVP

Hello Antony,

When you write that you want to focus on printing the data, do you mean actually printing to a device?

You can open the Print dialogue of most modern browsers with javascript through the print method - you can use this dialogue to both print to a PDF, or send the page to a physical device for a paper copy.

Whenever you want to tackle a custom layout for your PDFs, you can take a look at the UltimatePDF component - it has a demo module that you can download to check code examples.

UserImage.jpg
Antony Kauã

It could be like, I have a PDF template here, which I turned into a form so that people can fill it out online instead of manually. So when they fill it out and click the print button, the PDF template I have should be made available for download with the data they entered into the form integrated into the PDF. How could I achieve this? 

2023-05-25 06-24-18
Arif Baig

Hi Antony,

There is a function to print menu via JavaScript (window.print();).  

https://www.outsystems.com/forums/discussion/63732/print-a-document-in-reactive/

Thanks 

Arif 

UserImage.jpg
Antony Kauã

So this issue with window.print() will take a screenshot of the screen, and I don't want that 

2024-07-05 14-16-55
Daniël Kuhlmann
 
MVP

Hi,

The most used component on the OutSystems Forge to generate PDF documents based on data entered into OutSystems database through is: 

https://www.outsystems.com/forge/component-overview/5641/ultimate-pdf

Basically, this is the way to go in OutSystems:

  1. Build an app that handles the data entry and store the data in one or more outsystems entities
  2. Use the ultimate-pdf component to generate PDF documents.

Regards,

Daniel

2024-07-05 14-16-55
Daniël Kuhlmann
 
MVP

Please refrain from asking the same question multiple times.

This discussion can continue in your post with the same questions, and I close this post.

https://www.outsystems.com/forums/discussion/92319/automated-printing-of-form-filled-pdf-from-outsystems/