Jump to content
We've recently updated our Privacy Statement, available here ×

Converting HTML Report File to PDF appears blank using iTextPDF


mariumrafay

Recommended Posts

Hi;

I am using jasper server rest api to export report as html. I managed to export the report write it to html file and then reading html file to convert it to pdf using iTextpdf and xmlworker. But at the end my PDF report appears blank where as the output is coming correct in HTML.

 

Please help it's urgent

Link to comment
Share on other sites

  • Replies 2
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

You can use the JasperServer REST API to export direcly in PDF so no need to use any other things; you do it with a GET call  like:

http://<host>:<port>/jasperserver[-pro]/rest_v2/reports/path/to/report.pdf?<arguments>

You will find the dcoumentation in the Web Services Guide: http://community.jaspersoft.com/documentation/tibco-jasperreports-server-web-services-guide/v610/running-report

To your particular question; looks like the problem you have is in itext and xmlworker, since as you said the HTML comes correct. 

Link to comment
Share on other sites

  • 1 month later...

Hi,

I wonder whether you have worked it out. And I have only tried to convert PDF with the help of some 3rd party toolkits. When it comes to PDF conversion process, I have another question for you. I wonder have you ever tried to convert PDF to image files before? I am testing the related PDF to JPG converting, PDF to PNG converting, and PDF to BMP converting programs these days. Do you have experience about it?  Any suggestion will be appreciated. Thanks in advance.

 

 

 

Best regards,

Arron

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×
×
  • Create New...