Jump to content
JasperReports Library 7.0 is now available ×

Images in Html report output file


shiby

Recommended Posts

I have a web application that generates Jasper Reports in HTML and PDF formats. I have images within the reports. I am able to send the reports to the screen successfully with the images using ImageServlet.

But i need to write the same to a file in my hard disk, with the images showing in my (D:/report.html) output file. How can I achive this?

Also I need to send the report as a mail. There also the images are not coming in the mail.

 

Please help me. This is urgent

Link to comment
Share on other sites

  • Replies 3
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

Hi,

 

All the samples provided with the project show how to export a report into a HTML file.

As for emailing them, this is another story which is not related to JasperReports.

 

Just put JasperReports aside for a moment and try email a normal HTML file containing images. You'll probably have to encode the images into the email with Base64 encoding and things like that. This is something for you to dig.

 

I hope this helps.

Teodor

Link to comment
Share on other sites

Thanks a lot for the reply.

Ok.. I exported the report to a html file , but the images that are used to fill the background are shown in the file. While using JrHTMLExporter, i could make those images invisible, by setting the parameter JRHtmlExporterParameter.IS_USING_IMAGES_TO_ALIGN to false.

Is there any option to do the same when i use JasperExportManager.exportReportToHTMLFile??

Link to comment
Share on other sites

Hi,

 

The JasperExportManager is only a convenience class to get you stated with using JasperReports. If you want to leverage the power of individual exporter, you just need to instantiate and configure them as you already did.

You could just look into the manager source to see what it actually does and do the same, and set additional parameters to the HTML exporter as you need.

 

I hope this helps.

Teodor

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...