How to convert widget Container to PDF?

Hi Folks,
Greetings!

Please see below the screenshot of my tabular sheet design in Container (Outsystems widget)


this sheet is implemented in container so I would like to convert it into pdf.

Because this sheet should be print by printer so for that I need to convert this into pdf. If any other idea you people have to make hard copy of this sheet so kindly share me.

Also please let me know you expect more details from my side.


Thanks
 

Hi Meer,

Are you working on a reactive web app or a traditional web app?

If it's a traditional web app you can use the html2pdfConverter forge component to create a pdf of your screen.

If it's a reactive web app it'll be a bit trickier since there are no pdf components for it yet but you might try your luck with any of the mobile app components instead.

Kind regards,
Glenn

glenn michiels wrote:

Hi Meer,

Are you working on a reactive web app or a traditional web app?

If it's a traditional web app you can use the html2pdfConverter forge component to create a pdf of your screen.

If it's a reactive web app it'll be a bit trickier since there are no pdf components for it yet but you might try your luck with any of the mobile app components instead.

Kind regards,
Glenn

Hi glenn michiels,
Thanks for your reply.


I have checked multiple post on forum related to same my query and also checked html2pdfConverter but didn't used it because its name indicates html to pdf and in my scenario there is one part i.e. only one container have to convert to pdf.

Let me check html2pdfConverter, can there be option to convert container to pdf and then will get back to you.


Thanks


Hi Meer,

What you can do is isolate that container and its associated logic in a webblock. That way you can use that block in your current screen but also in a new screen that contains nothing else. This new screen would then be the one you use with the Html2PdfConverter component.

In Mobile I use the PDF Generator Plugin to create PDFs from screens. Perhaps you can also use this? 

Aurelio Junior wrote:

Hi Meer,

What you can do is isolate that container and its associated logic in a webblock. That way you can use that block in your current screen but also in a new screen that contains nothing else. This new screen would then be the one you use with the Html2PdfConverter component.

Hi Aurelio Junior,
Thanks, on this way I am going to implementing. But there asking for configuration so can you please tell the steps how to configure Html2PdfConverter component.


Meer Imtiyaz wrote:

Aurelio Junior wrote:

Hi Meer,

What you can do is isolate that container and its associated logic in a webblock. That way you can use that block in your current screen but also in a new screen that contains nothing else. This new screen would then be the one you use with the Html2PdfConverter component.

Hi Aurelio Junior,
Thanks, on this way I am going to implementing. But there asking for configuration so can you please tell the steps how to configure Html2PdfConverter component.


Hi Meer,

You can follow the instructions on screen when opening the html2pdf component in the browser. Once the screen loads you can click on installation instructions and it will guide you through the configuration process.

Regards,
Glenn


Solution

Hi Folks,

I got the simple way to convert screen to PDF without Htm2PdfConverter component using 


"window.print()"


Only need to create new screen and in Preparation action or any button action invoke RunJavaScript action with only "window.print()" this code.

This way fulfill my requirement. (Y)

Solution

Hi Meer,

Just keep in mind that this approach will require an additional step from your users (the print dialog) and that they have some sort of "print to pdf" printer installed on their machines. Components like Htm2PdfConverter allow your users to simply click a button and immediately download a pdf file.