[Simple Reports] Print directly PDF from other screen

Forge Component
(27)
Published on 31 Mar (9 days ago) by Rafael Fantato
27 votes
Published on 31 Mar (9 days ago) by Rafael Fantato

Hi,

I'm using HTML2PDF module to print my page with the simple reports directly (to be attached to an email).

It works if I opne the page, but I get an empty page when creating the pdf of the page, only with the header (in copy).

Any suggestion to get the right print in PDF directly?

Tomás Liaño wrote:

Hi,

I'm using HTML2PDF module to print my page with the simple reports directly (to be attached to an email).

It works if I opne the page, but I get an empty page when creating the pdf of the page, only with the header (in copy).

Any suggestion to get the right print in PDF directly?

Hi, Tomás. We saw it and we are trying to rollback some changes.

Previous version is it working because it doesn´t have a loading progress bar.

I actually have a beta that is almost working. As soon I get this 100% working, I´ll publish the new version.

\o/


Great Rafael!

Thanks for your fast feedback, I'll be waiting for it, thanks again

Dear Rafael,

any update on this issue? I've tried all kind of workarounds, but nothing works...

Thanks

Hi Rafael, 

testing again now from the server directly, I was able to print mostly well your demo page, http://rafaelfantato.outsystemscloud.com/SimpleReportsDemo/

attached, but not mine, gonna investigate the differencies, but not sure is the same demo and config as in the demos pages in the component... It seems as a clue to follow the investigation...

Thanks 

Hi again Rafael,

sorry to continue with the issue, but investigating further, I wasn't able to get a good PDF from anywhere in the server, so I tried installing the component in my personal environment, and that's it, it works!!

So it's related to the server itself, no idea what's causing the issue, but I found is related to the server config, maybe firewall?

Thanks for your help and knowledge

Hi Rafael, 

In fact your component works great with HTML2PDF, the issue seems to be related to some configuration in pour farm environment, because if i do a call to the binarie wkhtmltopdf, from the command prompt inside the server, or same inside the action, look what happens:

wkhtmltopdf http://rafaelfantato.outsystemscloud.com/SimpleReportsDemo testnew.pdf

Works!!

wkhtmltopdf https://tlianojover.outsystemscloud.com/SimpleReports/Home.aspx testnewsimple-mycloud2.pdf

works also

But, if I use the server:

wkhtmltopdf https://connect-dev.puratos.com/SimpleReports  testnewsimple-entry.pdf

3 pages empty...

I'm attaching you the examples so you can see better, the issue is the farm server config, it affects somehow...

Just the PDF that doesn't work, so you see...

Solution

Hi Rafael, 

finally I found the reason, so the working version to be used is Simple.Reports-4.0.0_O10, then I install it in the OS11 platform, and it worked. Don't know how I got here, but it was the issue...

So installing that version everything works!!

Solution

Tomás Liaño wrote:

Hi Rafael, 

finally I found the reason, so the working version to be used is Simple.Reports-4.0.0_O10, then I install it in the OS11 platform, and it worked. Don't know how I got here, but it was the issue...

So installing that version everything works!!


Yes, the new version made by a member of this component did some improvements like break injected html and a preloading progress bar, but it works fine for browser, not for html2pdf component, because html2pdf render the PDF when page is ready and with a progress bar, the page is ready before all adjustments by JS is done.

I'm still looking for a good solution that work on both and I could keep the html block inside Simple Reports. :(

Or I discard changes and go rollback to a previous version like you did.

Keep me informed if you solve it in the new version, 

Thanks