Difference between DOCX and PDF output or how to send a DOCX directly to printer

Hello, I have a question regarding the difference in output between printing to docx and pdf.

I have a template in docx for printing several entities, where I made the header very small and the startmargin for the document is 0,1cm. When printing to docx the output is like I want it to be, however when I run the same report with pdf export the margins I want are gone and also the header is back to its original size. I run the report from a ServiceBean, because the report has to run automatically based on certain actions from the user. Is there a way to get my docx output the same as the pdf output or how can I send the docx directly to printer?

Export to docx:

Export to PDF:

TIA, Willem.

1 Like

Hi,
did you use LibreOffice or OpenOffice for PDF conversion? Using LibreOffice increases conversion accuracy.

See here for details:

As for printing reports, you may take a look at this topic.

Thanks for the reply, I already did find the topic (which was very helpful). This was my starting point in printing reports and converting them to pdf.

I did install LibreOffice, for the most basic invoices it is ok. What I mean by that is that in 90% of my reports it gives me a copy from the doxc template in PDF. However when printing labels I had no other choice but start using HTML templates (using CSS) and converting them to PDF.

That gave me a good pdf output, better a good control over eg. where I want a barcode how high the labels can be etc.

I haven’t however tried Jasper Reports, it is on my todo list.