I'm trying to convert a .xls
file to .pdf
using LibreOffice via command line on Ubuntu. I have a kind of report on the .xls
file with some colors in the background of the cells and etc.
The problem is when I convert the .xls
file, the .pdf
loses the original format. Each page is broken almost in the half and the content of one page is displayed in two different pages.
- Does anybody know how to convert the
.xls
file to.pdf
via command line with keeping the original format? - Or some trick to set the size of the
.pdf
page to not break pages? (Also via command line)
The code I used to make the conversion was:
soffice --headless --convert-to pdf:"impress_pdf_Export" filename.xls