We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Background image not showing

Hi,

I’m a newbie in Aspose/JasperReports. I’m trying to create DOC and PDF report using Aspose/Jasper Report.
The document should have a background image: it always goes fine with the PDF document, but I’ve found no way to get the same with DOC document.

Here you find my code where I call the background image:


The version I’m using is: aspose.words.jasperreports-5.5.0.jar

Thank you in advance.


PS: You’ll find in the attachments full xml code and word document as exported.

Hi Fabrizio,

Thanks for your inquiry. Could you please attach following files for testing? I will investigate the issue on my side and provide you more information.

  • Please supply us with the Jrxml files along with xml/csv data source
  • Please supply us with the .jrprint file of your jrxml. Please check the attached image about exporting the Jrxml to Jrprint.
  • Please supply us with the Aspose.Words code from your application.

As soon as you get these pieces of information to us we’ll start our investigation into your issue.

Hi Tahir,

in the attached file you’ll find:
- folder exports: my pdf and word document as exported by aspose where the background image is only in the pdf document
- folder images: images colled from jrxml
- folder jrprint: jrprint of report.jrxml and head.jrxml (the latter is a subreport of the former)
- folder styles
- jrxml files

As far as the code is concerned, the problem is that the application is very complex. Several Java classes are involved.
Are there any methods or classes you think are more likely to investigate?

I was wondering, why if the pdf comes out properly, the word document doesn’t?

Please tell me if you need other pieces of information.

Thank you in advance.

Hi Fabrizio,

Thanks for sharing the detail. I have tested the scenario and have managed to reproduce the same issues at my side. For the sake of correction, I have logged these problems in our issue tracking system as follow:

WORDSJSP-147 : Header image does not render correctly after conversion from JRXML to Docx/Doc
WORDSJSP-146 : Background image does not visible after conversion from JRXML to Docx/Doc

I have linked this forum thread to the same issues and you will be notified via this forum thread once these issues are resolved.

We apologize for your inconvenience.