Hello everyone.


How do I generate a PDF by clicking a button and downloading it directly?


I tried using the Html2PdfConverter, but I can't.


Would you help me?

Hello Rodrigo,

What's the issues you're getting with the Html2PdfConverter? Usually you need to configure the plugin following the documentation of it, then you need to create a web page and set it as anonymous to download the Pdf. You also have more PDF Plugins to do that.



Use Ultimate PDF, it doesn't require any configuration so it's easier to use. Call the PrintToPDF action and give it the url of the page you want to convert. Then feed the binary data from that to a download widget.

Hi,

There is this: https://www.outsystems.com/forums/discussion/17923/html2pdfconverter-faq/  that explains how to configure the component.

Hope this helps :)

I have this problem...

I do not understand how the plugin works.
I made my flow equal to the flow of the demo version, but I have this error.



Rodrigo Lima wrote:

Hello everyone.


How do I generate a PDF by clicking a button and downloading it directly?


I tried using the Html2PdfConverter, but I can't.


Would you help me?

Hi Rodrigo, 

A simple example for what Tiago suggested: You can have a button that runs an action. In this action you will have the "GeneratePDF" action of the HtmlToPdfConverter component. In its URL field, you pass the path for another screen (with anonymous checked) that will only have the objects that you want to print on a pdf. Then, after the GeneratePDF action, you need to end the flow with a "Download", where you specify the filename with the pdf format (e.g.: "Test.pdf") and the mime-type (usually is "application/octet-stream"). 

The URL path of the other screen might be like this: "environmentName/ModuleName/Screen.aspx"
Does this works for you?

If it doesn't, maybe you can explain with more detail what you're trying to do.

Hope I could help

Vera,

I did exactly as you said. But the error remains.

Solution

Have you uploaded the binaries for the plugin? See https://www.outsystems.com/forums/discussion/17923/html2pdfconverter-faq/

Solution

Rodrigo Lima wrote:

Vera,

I did exactly as you said. But the error remains.


Hello Rodrigo, what is the URL input that you're sending in the GeneratePDF2 action. From what it seems that could be the problem. 

Good Morning !


I apologize for the delay, but I ended up using another component.

Then I tried again to configure [Html2PdfConverter] and be able to use it.

I downloaded this version below as per the instructions.


And then upload the binary files first, and then the executables. And it worked !!


Thank you!!